logo

Assignment on the Application of Room Carpet

   

Added on  2021-06-15

29 Pages3346 Words81 Views
0Running head: ROOM CARPET SHOP APPLICATIONRoom Carpet Shop ApplicationName of the student:Name of the University:Author note:
Assignment on the Application of Room Carpet_1
11ROOM CARPET SHOP APPLICATIONTable of ContentsObject-Oriented Programming........................................................................................................3Characteristics..............................................................................................................................3Advantages of using Object Oriented Programming...................................................................6Design Requirements.......................................................................................................................7UML Class Diagram....................................................................................................................8Use Case Diagram.......................................................................................................................8Programming Evidence.................................................................................................................10Output Screenshots........................................................................................................................14Testing Plan...................................................................................................................................16Range Testing............................................................................................................................16Functionality Testing.................................................................................................................19
Assignment on the Application of Room Carpet_2
22ROOM CARPET SHOP APPLICATIONObject-Oriented ProgrammingCharacteristicsObject Oriented Programming or OOP, as it is commonly known as is a very crucialaspect of modern day application development. Object oriented Programming is based on thefoundations and uses of classes and objects (Clark and Sanders 2013). Classes can be defined asthe design plans of blueprints of any program. Classes consist of all the required data membersand the member methods, which encapsulate into one unit in order to resemble a real life entity.Classes can be used to produce several such similar entities of its own type, these are known asobjects. The objects are there known as the real life instances of a class. Objects consists of dataand member methods of their own. They inherit these characteristics and behaviors from theirrespective classes. These characteristic features for every object are also known as membervariables because their values are updatable at any point of time for the particular object. Thebehavioral set for the objects are defined by the member methods that it contains. The methodsor functions assist the objects to efficiently execute and perform different operations. It is saidthat the objects communicate among themselves with the help of methods. The methods helps topass values within the object oriented programming paradigm, thus assisting the processingmechanism. These processed information are then either produced to the user or stored withinthe object’s instances (Dennis, Wixom and Tegarden 2015).Clark and Sanders (2013), says Object Oriented Programming makes use of manyfeatures to enhance the programming and development experience. The major object orientedfeatures are listed and explained in details below:
Assignment on the Application of Room Carpet_3
33ROOM CARPET SHOP APPLICATIONClasses and Objects: As depicted before, classes characterize the information designs andthe techniques while objects are made as the examples of such classes to take aftergenuine elements of the similar sort or type. A few attributes impart between each otherutilizing the inward part behaviors or methods.Encapsulation and Data abstraction: Encapsulation is an extremely regular OOP idea thatties a few member data and member methods together into one unit known as the class.Wrapping of data and functions into a solitary unit is known as Encapsulation. These dataand member methods are kept protected from the outer cases that may meddle with theinformation and the functionalities. The object oriented programming languages allow itsclasses to implement explicit access limitations such us to signify inner data as private orprotected before the outer world. This goes under the pennant of the data abstractionideas. Data abstraction, therefore can be defined as the process of providing onlyimportant information to the outside modules by hiding the inner implementation details(Milanesi 2018).Example:classEmployee{privateint ssn;privateString empName;privateint empAge;//Getter and Setter methodspublicint getEmpSSN(){return ssn; }publicString getEmpName(){return empName; }publicint getEmpAge(){return empAge; }publicvoid setEmpAge(int newValue){
Assignment on the Application of Room Carpet_4
44ROOM CARPET SHOP APPLICATION empAge = newValue; }publicvoid setEmpName(String newValue){ empName = newValue; }publicvoid setEmpSSN(int newValue){ ssn = newValue; }}publicclassOffice{publicstaticvoid main(String args[]){Employee obj = newEmployee (); obj.setEmpName("Mario"); obj.setEmpAge(32); obj.setEmpSSN(112233);System.out.println("Employee Name: " + obj.getEmpName());System.out.println("Employee SSN: " + obj.getEmpSSN());System.out.println("Employee Age: " + obj.getEmpAge()); } }Output:Employee Name: MarioEmployee SSN: 112233Employee Age: 32Source: (Singh et al., 2018)Inheritance: Inheritance is the procedure by which a class inside a specific object orientedprogram bundle acquires certain individuals from a main or existing class. The child classas it is known as, get the available properties from another class, which is regularlyknown as the parent or the root class. This idea gives the various leveled arrangements orhierarchy of the classes and objects that are expected to connect with each other in orderto execute a greater framework. Inheritance is one of the key highlights of OOPparadigm, which helps the programmers with the re-usage of existing code and in themeantime instantiate the various objects of classes with relevance to the hierarchical
Assignment on the Application of Room Carpet_5
55ROOM CARPET SHOP APPLICATIONarchitecture. This proposes a module or data that exists in an earlier class can be added toanother with no compelling reason to change it. This additionally decreases the spacecomplexity of bigger projects as similar information isn't being put away or introducedagain and again. Rather, the data individuals are being initialized once in the parent classand are further being exquisitely utilized by the child classes by simply makingoccurrences of themselves (Zeigler 2014).Examples:classTeacher{String designation ="Teacher";String collegeName ="Beginnersbook";void does(){System.out.println("Teaching");}}publicclassPhysicsTeacherextendsTeacher{String mainSubject ="Physics";publicstaticvoid main(String args[]){PhysicsTeacher obj =newPhysicsTeacher();System.out.println(obj.collegeName);System.out.println(obj.designation);System.out.println(obj.mainSubject);obj.does();}}Output:BeginnersbookTeacherPhysicsTeachingSource: (Java et al., 2018)Polymorphism: Polymorphism is the feature that enables anything to achieve more thanjust a single form. In Object oriented programming, the programs executes the idea of
Assignment on the Application of Room Carpet_6

End of preview

Want to access all the pages? Upload your documents or become a member.

Related Documents
Object Oriented Programming Concepts and Design Specifications
|22
|3872
|249

Unit 20 Advanced Programming - Assignment
|31
|3536
|337

Object Oriented Design for Genetic Algorithm Solver
|8
|1573
|93

Assignment on Application Development
|28
|9269
|140

IMAT5205: Systems Analysis And Design Assignment
|12
|2002
|148

Assignment on Explaining Polymorphism
|11
|1647
|313