Your SlideShare is downloading. ×
0
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Java tutor  oo ps introduction-version 1
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Java tutor oo ps introduction-version 1

437

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
437
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
7
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • http://www.eweek.com/c/a/Application-Development/Java-C-C-Top-18-Programming-Languages-for-2011-480790/ - Top programming languagehttp://www.siliconrepublic.com/careers/item/26777-java-net-and-c-develop - Survey Result for Java jobshttp://pages.cs.wisc.edu/~hasti/cs368/JavaTutorial/NOTES/Java_vs.htmlChange: Capital letters
  • http://journals.ecs.soton.ac.uk/java/tutorial/java/objects/object.html
  • http://wiki.tcl.tk/13398http://www.dotnetperls.com/oopObjectsObjects are the basic run-time entities in an object-oriented system. Programming problem is analyzed in terms of objects and nature of communication between them. When a program is executed, objects interact with each other by sending messages. Different objects can also interact with each other without knowing the details of their data or code.ClassesA class is a collection of objects of similar type. Once a class is defined, any number of objects can be created which belong to that class.Data Abstraction and EncapsulationAbstraction refers to the act of representing essential features without including the background details or explanations. Classes use the concept of abstraction and are defined as a list of abstract attributes. Storing data and functions in a single unit (class) is encapsulation. Data cannot be accessible to the outside world and only those functions which are stored in the class can access it.InheritanceInheritance is the process by which objects can acquire the properties of objects of other class. In OOP, inheritance provides reusability, like, adding additional features to an existing class without modifying it. This is achieved by deriving a new class from the existing one. The new class will have combined features of both the classes.PolymorphismPolymorphism means the ability to take more than one form. An operation may exhibit different behaviors in different instances. The behavior depends on the data types used in the operation. Polymorphism is extensively used in implementing Inheritance.
  • http://class.ezinemark.com/top-10-interview-questions-on-object-oriented-programming-16fd36abfc7.html
  • Do not use full stops if information define by bullet (Mainly if information are 1 line). have a purpose: projects have clearly-defined aims and set out to produceclearly-defined results. Their purpose is to solve a “problem”, and this involves analysingneeds beforehand. Suggesting one or more solutions, it aims at lasting social change.Projects are realistic: their aims must be achievable, and this means takingaccount both of requirements and of the financial and human resourcesavailable.Projects are limited in time and space: they have a beginning and an end,and are implemented in a specific place and context.Projects are complex: projects call on various planning and implementation skills, andinvolve various partners and players.Projects are collective: projects are the product of collective endeavour. They are run byteams, involve various partners and cater for the needs of others.Projects are unique: all projects stem from new ideas. They provide a specific responseto a need (problem) in a specific context. They are innovative.Projects are an adventure: every project is different and ground-breaking; they alwaysinvolve some uncertainty and risk.Projects can be assessed: projects are planned and broken down into measurable aims,which must be open to evaluation.Projects are made up of stages: projects have distinct, identifiable stages (see Chapter 3:The project: step by step).
  • http://www.javacoffeebreak.com/faq/faq0002.html
  • http://en.wikipedia.org/wiki/File:Bird.parts.jpg
  • http://en.wikipedia.org/wiki/Java_syntax
  • Transcript

    • 1. Object oriented programmingPresenting Object oriented Programming (Java) and aspects of management of project. Presented by Uday Sharma 1
    • 2. Why this tutorial?To gain knowledge of Object Oriented ProgrammingWhy this tutorial for java why not for C++?• Aim to do practice on Object Oriented programming and understanding of basic needs to be a programmer• Knowing C++ or Java will not make us a programmer but understanding of project, project requirement , project management are really important• Company demand force you to work on different technology• Right platform to learn something new what we do not know 2
    • 3. Why this tutorial?Why java ?• Open source package• Wastly useful in Web technology Java developers and general software developers in permanent• Java Embedded technology roles get an average salary of• Client / Server application between €42,000 and €60,000 per• Graphical user interface year in 2012. This compares to an average salary of €40,000 to• Design patterns €55,000 in 2011.• Test-driven development APIs However, in London, Java developers managed to get an average salary of between €66,000 and €107,000, while in Sydney, they could get salaries of between €73,000 and €105,000. 3
    • 4. After Student life CVObjectiv: bla bla –Study : bla bla–Programminglanguage : C, C++ InterviewProject work : Java 4
    • 5. What is object – oriented?Object Properties Barking State(Varia Entity ble) (Methods) Name Barking Biting Color Play Breed Slobber Hungry Biting Germany Asian country Money No rains money 5
    • 6. Why object oriented necessary ? 4 2 3 1 5 6 7 Parts/Objects/Member of ballpenBallpen 6
    • 7. Why object oriented necessary ? Properties of Parts/Objects/Member Part 1 Part 2 Part 3 Part 4 Part 5 Part 64 1 6 Name Name Name Name Name Name Color Color Color Upper- Color Ink- Color 3 Size Size Size Size Size Size Grip Grip Grip Grip Grip Grip 7 Notch Notch Notch Notch 2 Size Shape Shape Round Shape Shape Shape 7
    • 8. Object oriented programming types• Java• C#• .Net• PHP• Python• C++• Lisp• Ruby on Rain• Objective- C• Matlab• Lisp 8
    • 9. Real time example of OOPs Concept Sun Rise Ltd Sun Rise Ltd Class Ballpen Sun Rise Ltd. Ballpen S.Class S.Class S.Clas 3 1 3 s2 2 1 S.Clas S.Clas s5 s6 Sub Class of Sub Class of Sub Class of class Ballpen class Ballpen class Ballpen Class 7. Inheritance 7 6 Sub class of class 1 Name, shape,color and grip, DiameterClass of class 2 Encapsulation 5 Member of Class 6, Class 7, Class 1, Class 2 9
    • 10. Interview question• What is an Object in OOPS?• What is an Attribute in OOPs?• What is a Entity in OOPS?• What is an Identity in OOPS?• What is Encapsulation in OOPS?• What is Inheritance in OOPS?• What is Polymorphism in OOPS?• What is Compile Time Polymorphism in OOPS?• What is Run Time Polymorphism in OOPS?• What is Access Modifier in OOPS? 10
    • 11. Characteristic of project?• Project have a purpose• Project are realistic• Project have duration• Project are complex• Project are collective• Project are unique• Project are adventure• Project can be assessed• Project are made up of stages 11
    • 12. OOP: model, map, reusability , extention Object • Model the real world Data problem to user’s Method perceive Method • Use similar metaphor in computational env. Construct reusableObject Object components Data • Create new DataMethod components from MethodMethod existing ones Method 12
    • 13. Examples of objects 13
    • 14. Classes: Objects with the same attribute and behaviorPerson Object Abstract Person Class into Attributes: Name, Age, Sex Method :Speak(), Listen(), Walk()Vehicle Object Vehicle Class Abstract Attributes: Name, Model, Car into Method :Start(), Stop(), Accelerator()Polygon Object Polygon Class Abstract Attributes: Vertices, border, color, Fillcolor into Method :Draw(), Erase(), Move() 14
    • 15. Object Oriented Paradigm Encapsulation Data Abstration Single Inheritance OOP PolymorphysmParadigm Persistance Delegation Genericity Multiple Inheritance 15
    • 16. Encapsulation Encapsulation It associates the code Data Abstration and the data it Single Inheritance manipulates into a OOP Polymorphysm single unit andParadigm Persistance keeps them safe from Delegation external interference Genericity and misuse Multiple Inheritance 16
    • 17. Data Abstraction Encapsulation • The technique of Data Abstration creating new data types that are well suited to an Single Inheritance application OOP Polymorphysm • It allows the creation ofParadigm Persistance user defined data types, Delegation having the properties of built data types and a set Genericity of permitted operators Multiple Inheritance • In Java, partial support • In C++, fully supported (e.g., operator overloading) 17
    • 18. Abstract Data Type• A structure that contains both data and the actions to be performed on that data• Class is an implementation of an Abstract Data Type 18
    • 19. ClassClass is a set of attributes and class Account {operations that areperformed on the attributes. //Attributes of account. private String accountName; private double accountBalance; Account +accountName //Entity of account. +accountBalance public withdraw(); +withdraw(); public deposit(); +deposit(); public determineBalance(); +determineBal(); } / / Class Account 19
    • 20. Access ModifierPrivate :Protected:Public: Protected: Drinking beer Private: Drinking beer Public: Drinking beer 20
    • 21. ExerciseCar --- Create class for carBird --- Create class for Bird 21
    • 22. Solution for car Car BMW- hasNumberPlate - hasType- hasNoDoors - hasName - hasColor - hasEngineType - hasShape+ setDoors() + setDoors(hasshape,hasNoDoors)+setRoof() +setRoof(hasshape)+setGlass() +setGlass(hasShape)+setHeadlight() +setHeadlight(hasShape)+setWheel() +setWheel(hasShape) +setEngine() 22
    • 23. Bird Example 23
    • 24. Solution for bird Bird Parrot- hasHeight - hasType- hasWidth - hasName - hasbackColor,wingscolor.... - hasHeight+ setEye() - hasWidth+setLeg() - hasShape+setWing() + setWing(hasColor)+setThroat() +setLeg(hasShape)+setNape() +setWing(wingcolor)+setBack() +setBill(hasShape)+setBill() +setTail(hasShape)+setTail 24
    • 25. Inheritance• New data types (classes) can be defined as extensions to previously defined types• Parent Class (Super Class) – Child Class (Sub Class)• Subclass inherits properties from the parent class Parent Inherited Capability Child 25
    • 26. Inheritance-Example• Example • Define Person to be a class • A Person has attributes, such as age, height, gender • Assign values to attributes when describing object • Define student to be a subclass of Person • A student has all attributes of Person, plus attributes of his/her own ( student no, course_enrolled) • A student has all attributes of Person, plus attributes of his/her own (student no, course_enrolled) • Define lecturer to be a subclass of Person • Lecturer has all attributes of Person, plus attributes of His/her own ( staff_id, subjectID1, subjectID2) 26
    • 27. Inheritance- ExampleCircle Class can be a subclass (inherited from ) of a parent class -Shape 27
    • 28. References• [<Project Management> <Youth partnership> <Page> http://youth- partnership-eu.coe.int/youth- partnership/documents/Publications/T_kits/3/2_project.pdf >] 28

    ×