SlideShare a Scribd company logo
1 of 35
Think With Java
Mapping Real World Object with Java
A Society ( Group of families)
A Society ( Group of families)
Everything in the World is an Object (Society,
Family, Human, Cat, Dog, Car, River)
A society is a group of families.
Families are collections of Family member.
Each Family member is Human or Non Human.
Each family member has some responsibilities
(Activity) and they have their own properties.
Family members are interconnected to each
other.
A Society ( Group of families)
Each member is a human or non human.
Human beings are persons.
Each Human has common behavior comes
from Animal.
Each family member uses their guardians
vehicle or their own.
Each and every Human being has their own
Address.
Humans(Objects) Behavior
Object is an entity which has
State: determined by the values of its
properties.
Behavior: determined by how an object
performs an activity.
Humans(Objects) Properties &
Behavior/Activity
Every human(Male / Female / Other) has
common properties and also they have their
Behavior.
Properties: Name, Head, Hands, Hair,
Eyes(color , size), Nose, Address.
Behavior: Walking, Running, Playing, Gaining
Knowledge, Talking.
Map Now the Real World
Objects
Java Class or Java Bean
A simple Object instance container.
It has some properties and behavior.
So we can map our real world objects through
Java .
Properties: nationalId,
name, Address,
vehicle, PassportInfo,
Occupation
Behavior: Walking,
Running, Shopping,
Talking, Cycling,Driving
Access Modifier in java for
properties and behavior
Public:
A declaration that is accessible to all classes
with keyword “public”
Private:
A declaration that is accessible only to the class
in which it is declared with “private”.
Access Modifier in java for
properties and behavior
Java OOP feature(Abstraction)
Customer should
know to buy something
BillingStaff should
know products pricing
and to generate bill.
Administrator should
product sell and to buy
new products to gain
business goal and to
manage everything in
ABSTRACTION: concept of identifying the essential details to be
known and ignoring the non-essential details from the perspective
of the end user.
Retail Shop Scenario
A simple Shopping Scenario
of Abstraction
Encapsulation
The Student don’t have to know the calculation
mechanism of Calculator.
He/she just know its use of button.
ENCAPSULATION: concept of hiding the internal
details and providing a simple interface to the end
user which ensures that the system can be used
without having to know how it works.
A Calculator Scenario
of Encapsulation
Inheritance
Each Human have some common behavior of
Animal.
Every family members are human or non-
human(Cat or dog).
Each Regular or Privileged Customer have
common Properties.
Different Inheritance
Inheritance
Allows to define the generalized and
specialized characteristics and behavior. Multiple Inheritance
Inheritance
Allows to define the generalized and
specialized characteristics and behavior.
Multi level Inheritance
Polymorphism
Let us revisit the payment activity in the retail shop
Paymlent of bill can be done in two modes
Cash(Calculation includes VAT)
totalAmount = purchaseAmount + VAT
Credit Card(Calculation includes processing charge and
VAT)
totalAmount = purchaseAmount + VAT+
processingCharge
POLYMORPHISM: concept which allows on
objecct/operation to behave differently in different
situations.
So ? Now it is payment(processingCharge) or
payment()?
Polymorphism
Polymorphism is the
capability of a method
to do different things
based on the object
that it is acting upon
Following concepts
demonstrate different
types of polymorphism
in java.
1) Method
Overloading
2) Method
Static Binding vs Dynamic
Binding
difference between static and dynamic
binding in Java.
Static binding happens at compile-time while
dynamic binding happens at runtime.
Binding of private, static and final methods
always happen at compile time since these
methods cannot be overridden. Binding of
overridden methods happen at runtime.
Java uses static binding for overloaded
methods and dynamic binding for overridden
methods.
Dynamic Polymorphism(dynamic
binding) example
Abstract class & abstract
Method
If you declare an abstract
method (discussed below)
in a class then you must
declare the class abstract
as well. you can’t have
abstract method in a non-
abstract class.
What is an interface
Interface looks like class but it is not a class. An
interface can have methods and variables just
like the class but the methods declared in
interface are by default abstract (only method
signature, no body). Also, the variables declared
in an interface are public, static & final by
default.
** java programming language does not
support multiple inheritance (we can do this
through Interface)
Interface and abstract
Interface provides complete abstraction as
none of its methods can have body. On the other
hand, abstract class provides partial
abstraction as it can have abstract and
concrete(methods with body) methods both.
Use of Interface
Use of Interface with “abstract”
keyword
Relationship in Java classes
Is A (Inheritance)
Has A (Aggregation)  Tightly coupled
Uses (Association)  Loosely coupled
Relationship in Java classes
What next. . . . . .
ORM = Object Relational Mapping
ORM Providers : JPA, Hibernate, Spring, OFBiz
MVC = Model View Controller
MVC provider : JSF, Hibernate, Spring, OFBiz
etc.
A Strong Tool : Collection Framework
To work with data in the local machine or
memory must use the collection framework.
Collections--> Set, List, ArrayList, Map,
LinkedHashMap
Collection Framework overview.
Collections Example
Questions & Answers
 Fun with Java :)
Thanks to all…
Md. Arifur Rahman
Junior Software Engineer,
Newgen Technology Limited, Bangladesh.

More Related Content

What's hot

39f1b9a797dbms chapter2 b.sc2
39f1b9a797dbms chapter2 b.sc239f1b9a797dbms chapter2 b.sc2
39f1b9a797dbms chapter2 b.sc2Mukund Trivedi
 
39f1b9a797dbms chapter2 b.sc2 (1)
39f1b9a797dbms chapter2 b.sc2 (1)39f1b9a797dbms chapter2 b.sc2 (1)
39f1b9a797dbms chapter2 b.sc2 (1)Mukund Trivedi
 
friend function(c++)
friend function(c++)friend function(c++)
friend function(c++)Ritika Sharma
 
E-R diagram in Database
E-R diagram in DatabaseE-R diagram in Database
E-R diagram in DatabaseFatiha Qureshi
 
Entity Relationship Diagram
Entity Relationship DiagramEntity Relationship Diagram
Entity Relationship DiagramShakila Mahjabin
 
The entity relationship model
The entity relationship modelThe entity relationship model
The entity relationship modelJane Garay
 
Lecture#01, object orientation
Lecture#01, object orientationLecture#01, object orientation
Lecture#01, object orientationbabak danyal
 
Classes, objects, methods, constructors, this keyword in java
Classes, objects, methods, constructors, this keyword  in javaClasses, objects, methods, constructors, this keyword  in java
Classes, objects, methods, constructors, this keyword in javaTharuniDiddekunta
 
Entity Relationship Diagrams
Entity Relationship DiagramsEntity Relationship Diagrams
Entity Relationship Diagramssadique_ghitm
 
The entity relationship model
The entity relationship modelThe entity relationship model
The entity relationship modelyash patel
 

What's hot (19)

Class diagrams
Class diagramsClass diagrams
Class diagrams
 
39f1b9a797dbms chapter2 b.sc2
39f1b9a797dbms chapter2 b.sc239f1b9a797dbms chapter2 b.sc2
39f1b9a797dbms chapter2 b.sc2
 
39f1b9a797dbms chapter2 b.sc2 (1)
39f1b9a797dbms chapter2 b.sc2 (1)39f1b9a797dbms chapter2 b.sc2 (1)
39f1b9a797dbms chapter2 b.sc2 (1)
 
friend function(c++)
friend function(c++)friend function(c++)
friend function(c++)
 
java tr.docx
java tr.docxjava tr.docx
java tr.docx
 
E-R diagram in Database
E-R diagram in DatabaseE-R diagram in Database
E-R diagram in Database
 
Entity Relationship Diagram
Entity Relationship DiagramEntity Relationship Diagram
Entity Relationship Diagram
 
The entity relationship model
The entity relationship modelThe entity relationship model
The entity relationship model
 
Lecture#01, object orientation
Lecture#01, object orientationLecture#01, object orientation
Lecture#01, object orientation
 
8815346
88153468815346
8815346
 
Inheritance
InheritanceInheritance
Inheritance
 
Classes, objects, methods, constructors, this keyword in java
Classes, objects, methods, constructors, this keyword  in javaClasses, objects, methods, constructors, this keyword  in java
Classes, objects, methods, constructors, this keyword in java
 
Oo ps exam answer2
Oo ps exam answer2Oo ps exam answer2
Oo ps exam answer2
 
Demystifying oop
Demystifying oopDemystifying oop
Demystifying oop
 
Ch 3 E R Model
Ch 3  E R  ModelCh 3  E R  Model
Ch 3 E R Model
 
Inheritance used in java
Inheritance used in javaInheritance used in java
Inheritance used in java
 
Dbms question (3)
Dbms question (3)Dbms question (3)
Dbms question (3)
 
Entity Relationship Diagrams
Entity Relationship DiagramsEntity Relationship Diagrams
Entity Relationship Diagrams
 
The entity relationship model
The entity relationship modelThe entity relationship model
The entity relationship model
 

Viewers also liked

Mapping in Java Options
Mapping in Java OptionsMapping in Java Options
Mapping in Java OptionsAnna Pietras
 
Modulo 1 andrea perez
Modulo 1 andrea perezModulo 1 andrea perez
Modulo 1 andrea perezAndrea Peréz
 
DISCOVERING DIFFERENCES IN GENDER-RELATED SKELETAL MUSCLE AGING THROUGH THE M...
DISCOVERING DIFFERENCES IN GENDER-RELATED SKELETAL MUSCLE AGING THROUGH THE M...DISCOVERING DIFFERENCES IN GENDER-RELATED SKELETAL MUSCLE AGING THROUGH THE M...
DISCOVERING DIFFERENCES IN GENDER-RELATED SKELETAL MUSCLE AGING THROUGH THE M...ijbbjournal
 
Smart metering and energy efficiency application with CloudIndustries.eu
Smart metering and energy efficiency application with CloudIndustries.euSmart metering and energy efficiency application with CloudIndustries.eu
Smart metering and energy efficiency application with CloudIndustries.euEvaldas Paliliūnas
 
¿Cómo evitamos que se pudra la comida?
¿Cómo evitamos que se pudra la comida?¿Cómo evitamos que se pudra la comida?
¿Cómo evitamos que se pudra la comida?Ruben Lijo
 
Transportation Hubs Project
Transportation Hubs ProjectTransportation Hubs Project
Transportation Hubs ProjectSylviaTM
 
Diapositivas ejemplos sustentables
Diapositivas ejemplos sustentablesDiapositivas ejemplos sustentables
Diapositivas ejemplos sustentableshannakrn22
 
Informe de motor de arranque
Informe de motor de arranqueInforme de motor de arranque
Informe de motor de arranqueJohn Israel
 
Life.Film - EdHack - Chatbots Community
Life.Film - EdHack - Chatbots CommunityLife.Film - EdHack - Chatbots Community
Life.Film - EdHack - Chatbots Communitychatbotscommunity
 
Building RESTful API
Building RESTful APIBuilding RESTful API
Building RESTful APIAnna Pietras
 
Est 506.docx general soil profile
Est 506.docx general soil profileEst 506.docx general soil profile
Est 506.docx general soil profilejaya47
 
Contraception
ContraceptionContraception
Contraceptionakifab93
 

Viewers also liked (20)

Mapping in Java Options
Mapping in Java OptionsMapping in Java Options
Mapping in Java Options
 
Modulo 1 andrea perez
Modulo 1 andrea perezModulo 1 andrea perez
Modulo 1 andrea perez
 
DISCOVERING DIFFERENCES IN GENDER-RELATED SKELETAL MUSCLE AGING THROUGH THE M...
DISCOVERING DIFFERENCES IN GENDER-RELATED SKELETAL MUSCLE AGING THROUGH THE M...DISCOVERING DIFFERENCES IN GENDER-RELATED SKELETAL MUSCLE AGING THROUGH THE M...
DISCOVERING DIFFERENCES IN GENDER-RELATED SKELETAL MUSCLE AGING THROUGH THE M...
 
Smart metering and energy efficiency application with CloudIndustries.eu
Smart metering and energy efficiency application with CloudIndustries.euSmart metering and energy efficiency application with CloudIndustries.eu
Smart metering and energy efficiency application with CloudIndustries.eu
 
Grammar 3 rd term
Grammar 3 rd termGrammar 3 rd term
Grammar 3 rd term
 
¿Cómo evitamos que se pudra la comida?
¿Cómo evitamos que se pudra la comida?¿Cómo evitamos que se pudra la comida?
¿Cómo evitamos que se pudra la comida?
 
Flyer digital en
Flyer digital enFlyer digital en
Flyer digital en
 
Vou subir elaine de jesus
Vou subir   elaine de jesusVou subir   elaine de jesus
Vou subir elaine de jesus
 
Transportation Hubs Project
Transportation Hubs ProjectTransportation Hubs Project
Transportation Hubs Project
 
Diapositivas ejemplos sustentables
Diapositivas ejemplos sustentablesDiapositivas ejemplos sustentables
Diapositivas ejemplos sustentables
 
Informe de motor de arranque
Informe de motor de arranqueInforme de motor de arranque
Informe de motor de arranque
 
Life.Film - EdHack - Chatbots Community
Life.Film - EdHack - Chatbots CommunityLife.Film - EdHack - Chatbots Community
Life.Film - EdHack - Chatbots Community
 
Building RESTful API
Building RESTful APIBuilding RESTful API
Building RESTful API
 
Espaço Público Urbano - Santiago
Espaço Público Urbano - SantiagoEspaço Público Urbano - Santiago
Espaço Público Urbano - Santiago
 
Interação com a comunidade - Paulo Silva (DCSPT)
Interação com a comunidade - Paulo Silva (DCSPT)Interação com a comunidade - Paulo Silva (DCSPT)
Interação com a comunidade - Paulo Silva (DCSPT)
 
Que existe y_que_no
Que existe y_que_noQue existe y_que_no
Que existe y_que_no
 
Quiromasaje
QuiromasajeQuiromasaje
Quiromasaje
 
Est 506.docx general soil profile
Est 506.docx general soil profileEst 506.docx general soil profile
Est 506.docx general soil profile
 
Clothing
ClothingClothing
Clothing
 
Contraception
ContraceptionContraception
Contraception
 

Similar to Think with java

Programming Laboratory Unit 1.pdf
Programming Laboratory Unit 1.pdfProgramming Laboratory Unit 1.pdf
Programming Laboratory Unit 1.pdfswapnilslide2019
 
Oops presentation java
Oops presentation javaOops presentation java
Oops presentation javaJayasankarPR2
 
Md02 - Getting Started part-2
Md02 - Getting Started part-2Md02 - Getting Started part-2
Md02 - Getting Started part-2Rakesh Madugula
 
Hibernate Training Session1
Hibernate Training Session1Hibernate Training Session1
Hibernate Training Session1Asad Khan
 
Object oriented programming
Object oriented programmingObject oriented programming
Object oriented programmingJun Shimizu
 
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...Sakthi Durai
 
Java Programming Paradigms Chapter 1
Java Programming Paradigms Chapter 1 Java Programming Paradigms Chapter 1
Java Programming Paradigms Chapter 1 Sakthi Durai
 
SAD02 - Object Orientation
SAD02 - Object OrientationSAD02 - Object Orientation
SAD02 - Object OrientationMichael Heron
 
Java is an Object-Oriented Language
Java is an Object-Oriented LanguageJava is an Object-Oriented Language
Java is an Object-Oriented Languageale8819
 
Review oop and ood
Review oop and oodReview oop and ood
Review oop and oodthan sare
 
CHAPTER 1 - OVERVIEW OOP.ppt
CHAPTER 1 - OVERVIEW OOP.pptCHAPTER 1 - OVERVIEW OOP.ppt
CHAPTER 1 - OVERVIEW OOP.pptNgoHuuNhan1
 
Abstraction1
Abstraction1Abstraction1
Abstraction1zindadili
 
introduction to machine learning
introduction to machine learningintroduction to machine learning
introduction to machine learningcolleges
 
Abstract class and Interface
Abstract class and InterfaceAbstract class and Interface
Abstract class and InterfaceHaris Bin Zahid
 

Similar to Think with java (20)

Programming Laboratory Unit 1.pdf
Programming Laboratory Unit 1.pdfProgramming Laboratory Unit 1.pdf
Programming Laboratory Unit 1.pdf
 
Oops presentation java
Oops presentation javaOops presentation java
Oops presentation java
 
Md02 - Getting Started part-2
Md02 - Getting Started part-2Md02 - Getting Started part-2
Md02 - Getting Started part-2
 
Hibernate Training Session1
Hibernate Training Session1Hibernate Training Session1
Hibernate Training Session1
 
Ontology
OntologyOntology
Ontology
 
Object oriented programming
Object oriented programmingObject oriented programming
Object oriented programming
 
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
Java Progamming Paradigms, OOPS Concept, Introduction to Java, Structure of J...
 
Java Programming Paradigms Chapter 1
Java Programming Paradigms Chapter 1 Java Programming Paradigms Chapter 1
Java Programming Paradigms Chapter 1
 
Uml - An Overview
Uml - An OverviewUml - An Overview
Uml - An Overview
 
SAD02 - Object Orientation
SAD02 - Object OrientationSAD02 - Object Orientation
SAD02 - Object Orientation
 
Java is an Object-Oriented Language
Java is an Object-Oriented LanguageJava is an Object-Oriented Language
Java is an Object-Oriented Language
 
java
javajava
java
 
Review oop and ood
Review oop and oodReview oop and ood
Review oop and ood
 
Java interfaces
Java interfacesJava interfaces
Java interfaces
 
CHAPTER 1 - OVERVIEW OOP.ppt
CHAPTER 1 - OVERVIEW OOP.pptCHAPTER 1 - OVERVIEW OOP.ppt
CHAPTER 1 - OVERVIEW OOP.ppt
 
Abstraction1
Abstraction1Abstraction1
Abstraction1
 
Java basics
Java basicsJava basics
Java basics
 
introduction to machine learning
introduction to machine learningintroduction to machine learning
introduction to machine learning
 
Abstract class and Interface
Abstract class and InterfaceAbstract class and Interface
Abstract class and Interface
 
2.oop concept
2.oop concept2.oop concept
2.oop concept
 

Recently uploaded

Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 

Recently uploaded (20)

Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 

Think with java

  • 1. Think With Java Mapping Real World Object with Java
  • 2. A Society ( Group of families)
  • 3. A Society ( Group of families) Everything in the World is an Object (Society, Family, Human, Cat, Dog, Car, River) A society is a group of families. Families are collections of Family member. Each Family member is Human or Non Human. Each family member has some responsibilities (Activity) and they have their own properties. Family members are interconnected to each other.
  • 4. A Society ( Group of families) Each member is a human or non human. Human beings are persons. Each Human has common behavior comes from Animal. Each family member uses their guardians vehicle or their own. Each and every Human being has their own Address.
  • 5. Humans(Objects) Behavior Object is an entity which has State: determined by the values of its properties. Behavior: determined by how an object performs an activity.
  • 6. Humans(Objects) Properties & Behavior/Activity Every human(Male / Female / Other) has common properties and also they have their Behavior. Properties: Name, Head, Hands, Hair, Eyes(color , size), Nose, Address. Behavior: Walking, Running, Playing, Gaining Knowledge, Talking.
  • 7. Map Now the Real World Objects
  • 8. Java Class or Java Bean A simple Object instance container. It has some properties and behavior. So we can map our real world objects through Java . Properties: nationalId, name, Address, vehicle, PassportInfo, Occupation Behavior: Walking, Running, Shopping, Talking, Cycling,Driving
  • 9. Access Modifier in java for properties and behavior Public: A declaration that is accessible to all classes with keyword “public” Private: A declaration that is accessible only to the class in which it is declared with “private”.
  • 10. Access Modifier in java for properties and behavior
  • 11. Java OOP feature(Abstraction) Customer should know to buy something BillingStaff should know products pricing and to generate bill. Administrator should product sell and to buy new products to gain business goal and to manage everything in ABSTRACTION: concept of identifying the essential details to be known and ignoring the non-essential details from the perspective of the end user. Retail Shop Scenario
  • 12. A simple Shopping Scenario of Abstraction
  • 13. Encapsulation The Student don’t have to know the calculation mechanism of Calculator. He/she just know its use of button. ENCAPSULATION: concept of hiding the internal details and providing a simple interface to the end user which ensures that the system can be used without having to know how it works.
  • 14. A Calculator Scenario of Encapsulation
  • 15. Inheritance Each Human have some common behavior of Animal. Every family members are human or non- human(Cat or dog). Each Regular or Privileged Customer have common Properties.
  • 17. Inheritance Allows to define the generalized and specialized characteristics and behavior. Multiple Inheritance
  • 18. Inheritance Allows to define the generalized and specialized characteristics and behavior. Multi level Inheritance
  • 19. Polymorphism Let us revisit the payment activity in the retail shop Paymlent of bill can be done in two modes Cash(Calculation includes VAT) totalAmount = purchaseAmount + VAT Credit Card(Calculation includes processing charge and VAT) totalAmount = purchaseAmount + VAT+ processingCharge POLYMORPHISM: concept which allows on objecct/operation to behave differently in different situations. So ? Now it is payment(processingCharge) or payment()?
  • 20. Polymorphism Polymorphism is the capability of a method to do different things based on the object that it is acting upon Following concepts demonstrate different types of polymorphism in java. 1) Method Overloading 2) Method
  • 21. Static Binding vs Dynamic Binding difference between static and dynamic binding in Java. Static binding happens at compile-time while dynamic binding happens at runtime. Binding of private, static and final methods always happen at compile time since these methods cannot be overridden. Binding of overridden methods happen at runtime. Java uses static binding for overloaded methods and dynamic binding for overridden methods.
  • 23. Abstract class & abstract Method If you declare an abstract method (discussed below) in a class then you must declare the class abstract as well. you can’t have abstract method in a non- abstract class.
  • 24. What is an interface Interface looks like class but it is not a class. An interface can have methods and variables just like the class but the methods declared in interface are by default abstract (only method signature, no body). Also, the variables declared in an interface are public, static & final by default. ** java programming language does not support multiple inheritance (we can do this through Interface)
  • 25. Interface and abstract Interface provides complete abstraction as none of its methods can have body. On the other hand, abstract class provides partial abstraction as it can have abstract and concrete(methods with body) methods both.
  • 27. Use of Interface with “abstract” keyword
  • 28. Relationship in Java classes Is A (Inheritance) Has A (Aggregation)  Tightly coupled Uses (Association)  Loosely coupled
  • 30. What next. . . . . . ORM = Object Relational Mapping ORM Providers : JPA, Hibernate, Spring, OFBiz MVC = Model View Controller MVC provider : JSF, Hibernate, Spring, OFBiz etc.
  • 31. A Strong Tool : Collection Framework To work with data in the local machine or memory must use the collection framework. Collections--> Set, List, ArrayList, Map, LinkedHashMap
  • 34. Questions & Answers  Fun with Java :)
  • 35. Thanks to all… Md. Arifur Rahman Junior Software Engineer, Newgen Technology Limited, Bangladesh.