SlideShare a Scribd company logo
1 of 15
Java Interfaces
Design Perspective
Chennai Java Summit - 2013

Manigandan Venkataraman
shivamanik@gmail.com
Agenda
●

Application

●

Interface – What is an Interface

●

Components and Interface

●

Java Interface

●

Abstraction & Interfaces

●

Design Patterns

●

Good Design Practices
Applications
●

Applications that can grow
●

Plugins and Addons

●

Examples
–
–

●

Application should grow
–

●

Browser - Firefox
IDE – Eclipse, Netbeans
Provide plugin/ addon design

How to design such an application???
Interface
●

What is an INTERFACE

●

Tell me the interface for this room
●

Doors

●

Windows

●

Interfaces are nothing but communication points

●

How do you interface with your Bike or Car

●

Interfaces to the Computer
●

USB, HDMI, VGA , Serial Ports

●

Will this device work with my computer????
Components
println

PrintWriter

Public Interfaces are API
sum(int,int)

MyCalculator
sub(int,int)

Component Interface = method signature + return type
Operation

WebService
operation
●

●

RMI – Stubs and
Skeletons
We need Remote
Interfaces to compile
the local code

●

●

Webservice
endpoints are
interfaces
Only interface and
NO LOGIC
Java Interface
●

A way to implement multiple inheritance

●

Interface is a collection of abstract methods
●

●

now, we can have default implemented methods too
.... :)

All methods in an interface are public
Abstraction
●

What does Abstract mean ???

●

I need to go to Mumbai – abstract statement
●

Whats missing
–
–
–

●

Means of transport
Date and time
Budget

I am travelling to Mumbai on Monday 7 am, by
Indigo – Concrete Statement
Abstraction
●

Your College Project
●

Abstract - ????
–
–
–

●

Problem Statement
Solution
Whats missing - How ??? The Implemention

Where's the Implementation
–

The whole project is the Implementation !!!! ;)
Abstraction
●

An idea without Implementation

●

Why do we need it??
●

Object Oriented Design

Interfaces have abstract methods
Abstraction and Interfaces
●

Runnable Interface
●

<Code>

●

What it does

●

JVM has to deal with unknown code

●

Its not aware of Our Code

●

Interface Design provides Loose Coupling

●

Eclipse Rich Client Platform

●

Netbeans Platform
Design Patterns
●

Mixture of Abstract Classes and Interfaces

●

No logic, only provides a guideline/approach

●

Upto to programmer to write an implementation
– logic
Good Design Practices
●

Program to an interface , not to implementation
●
●

●

Spring Framework
Code can grow, more implementations

clients remain unaware
●

●

●

of the specific types of objects they use, as long as the
object adheres to the interface
of the classes that implement these objects; clients only
know about the abstract class(es) defining the interface

Use of an interface also leads to dynamic binding and
polymorphism
Thank You

More Related Content

What's hot

Futuristic programing language
Futuristic programing languageFuturistic programing language
Futuristic programing languageMohamed Zaki
 
Review june2014 june2015
Review june2014 june2015Review june2014 june2015
Review june2014 june2015Ikuru Kanuma
 
Pair Programming (2015)
Pair Programming (2015)Pair Programming (2015)
Pair Programming (2015)Peter Kofler
 
Infinum Android Talks #19 - Stop wasting time fixing bugs with TDD by Domagoj...
Infinum Android Talks #19 - Stop wasting time fixing bugs with TDD by Domagoj...Infinum Android Talks #19 - Stop wasting time fixing bugs with TDD by Domagoj...
Infinum Android Talks #19 - Stop wasting time fixing bugs with TDD by Domagoj...Infinum
 
Create first android app with MVVM Architecture
Create first android app with MVVM ArchitectureCreate first android app with MVVM Architecture
Create first android app with MVVM Architecturekhushbu thakker
 
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)Matheus Marabesi
 
PHP Code Quality
PHP Code QualityPHP Code Quality
PHP Code QualityUsman Zafar
 
Tech Talk Tokyo #2 tetsuya matsuzawa
Tech Talk Tokyo #2 tetsuya matsuzawaTech Talk Tokyo #2 tetsuya matsuzawa
Tech Talk Tokyo #2 tetsuya matsuzawaRarejob
 
Design patterns in PHP - PHP TEAM
Design patterns in PHP - PHP TEAMDesign patterns in PHP - PHP TEAM
Design patterns in PHP - PHP TEAMNishant Shrivastava
 
Mvvm is like born fraction
Mvvm is like born fractionMvvm is like born fraction
Mvvm is like born fractionKen Haneda
 
HotelQuickly Product & Engineering
HotelQuickly Product & EngineeringHotelQuickly Product & Engineering
HotelQuickly Product & EngineeringMichal Juhas
 
Coding Dojo: Mars Rover (2014)
Coding Dojo: Mars Rover (2014)Coding Dojo: Mars Rover (2014)
Coding Dojo: Mars Rover (2014)Peter Kofler
 
Php[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersPhp[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersAdam Englander
 
Chapter 3 what is programming
Chapter 3   what is programmingChapter 3   what is programming
Chapter 3 what is programmingPro Guide
 
Your first 5 PHP design patterns - ThatConference 2012
Your first 5 PHP design patterns - ThatConference 2012Your first 5 PHP design patterns - ThatConference 2012
Your first 5 PHP design patterns - ThatConference 2012Aaron Saray
 
Introducing the JAQ (Java, Angular, Sql/NoSQL) Stack
Introducing the JAQ (Java, Angular, Sql/NoSQL) Stack Introducing the JAQ (Java, Angular, Sql/NoSQL) Stack
Introducing the JAQ (Java, Angular, Sql/NoSQL) Stack Suren Konathala
 
GDCR15 in Las Palmas, Gran Canaria
GDCR15 in Las Palmas, Gran CanariaGDCR15 in Las Palmas, Gran Canaria
GDCR15 in Las Palmas, Gran CanariaPeter Kofler
 

What's hot (20)

Futuristic programing language
Futuristic programing languageFuturistic programing language
Futuristic programing language
 
Review june2014 june2015
Review june2014 june2015Review june2014 june2015
Review june2014 june2015
 
Pair Programming (2015)
Pair Programming (2015)Pair Programming (2015)
Pair Programming (2015)
 
Infinum Android Talks #19 - Stop wasting time fixing bugs with TDD by Domagoj...
Infinum Android Talks #19 - Stop wasting time fixing bugs with TDD by Domagoj...Infinum Android Talks #19 - Stop wasting time fixing bugs with TDD by Domagoj...
Infinum Android Talks #19 - Stop wasting time fixing bugs with TDD by Domagoj...
 
Gem API design
Gem API designGem API design
Gem API design
 
Create first android app with MVVM Architecture
Create first android app with MVVM ArchitectureCreate first android app with MVVM Architecture
Create first android app with MVVM Architecture
 
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
 
PHP Code Quality
PHP Code QualityPHP Code Quality
PHP Code Quality
 
Tech Talk Tokyo #2 tetsuya matsuzawa
Tech Talk Tokyo #2 tetsuya matsuzawaTech Talk Tokyo #2 tetsuya matsuzawa
Tech Talk Tokyo #2 tetsuya matsuzawa
 
Design patterns in PHP - PHP TEAM
Design patterns in PHP - PHP TEAMDesign patterns in PHP - PHP TEAM
Design patterns in PHP - PHP TEAM
 
Mvvm is like born fraction
Mvvm is like born fractionMvvm is like born fraction
Mvvm is like born fraction
 
HotelQuickly Product & Engineering
HotelQuickly Product & EngineeringHotelQuickly Product & Engineering
HotelQuickly Product & Engineering
 
RealDay: Angular.js
RealDay: Angular.jsRealDay: Angular.js
RealDay: Angular.js
 
Coding Dojo: Mars Rover (2014)
Coding Dojo: Mars Rover (2014)Coding Dojo: Mars Rover (2014)
Coding Dojo: Mars Rover (2014)
 
Php[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersPhp[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for Beginners
 
Chapter 3 what is programming
Chapter 3   what is programmingChapter 3   what is programming
Chapter 3 what is programming
 
Your first 5 PHP design patterns - ThatConference 2012
Your first 5 PHP design patterns - ThatConference 2012Your first 5 PHP design patterns - ThatConference 2012
Your first 5 PHP design patterns - ThatConference 2012
 
Introducing the JAQ (Java, Angular, Sql/NoSQL) Stack
Introducing the JAQ (Java, Angular, Sql/NoSQL) Stack Introducing the JAQ (Java, Angular, Sql/NoSQL) Stack
Introducing the JAQ (Java, Angular, Sql/NoSQL) Stack
 
Accenture
AccentureAccenture
Accenture
 
GDCR15 in Las Palmas, Gran Canaria
GDCR15 in Las Palmas, Gran CanariaGDCR15 in Las Palmas, Gran Canaria
GDCR15 in Las Palmas, Gran Canaria
 

Viewers also liked

The list interface (the java™ tutorials collections interfaces)
The list interface (the java™ tutorials   collections   interfaces)The list interface (the java™ tutorials   collections   interfaces)
The list interface (the java™ tutorials collections interfaces)charan kumar
 
Java Programming - Abstract Class and Interface
Java Programming - Abstract Class and InterfaceJava Programming - Abstract Class and Interface
Java Programming - Abstract Class and InterfaceOum Saokosal
 
Java interfaces
Java interfacesJava interfaces
Java interfacesjehan1987
 
Abstract class and Interface
Abstract class and InterfaceAbstract class and Interface
Abstract class and InterfaceHaris Bin Zahid
 
Java - Interfaces & Packages
Java - Interfaces & PackagesJava - Interfaces & Packages
Java - Interfaces & PackagesArindam Ghosh
 
Java interfaces & abstract classes
Java interfaces & abstract classesJava interfaces & abstract classes
Java interfaces & abstract classesShreyans Pathak
 

Viewers also liked (9)

The list interface (the java™ tutorials collections interfaces)
The list interface (the java™ tutorials   collections   interfaces)The list interface (the java™ tutorials   collections   interfaces)
The list interface (the java™ tutorials collections interfaces)
 
Java Programming - Abstract Class and Interface
Java Programming - Abstract Class and InterfaceJava Programming - Abstract Class and Interface
Java Programming - Abstract Class and Interface
 
List interface
List interfaceList interface
List interface
 
Java interfaces
Java interfacesJava interfaces
Java interfaces
 
Java interface
Java interfaceJava interface
Java interface
 
Abstract class and Interface
Abstract class and InterfaceAbstract class and Interface
Abstract class and Interface
 
Java - Interfaces & Packages
Java - Interfaces & PackagesJava - Interfaces & Packages
Java - Interfaces & Packages
 
Java interfaces & abstract classes
Java interfaces & abstract classesJava interfaces & abstract classes
Java interfaces & abstract classes
 
Interface
InterfaceInterface
Interface
 

Similar to Java interfaces design perspective

HOW TO START (ANYTHING ABOUT CODE).pptx
HOW TO START (ANYTHING ABOUT CODE).pptxHOW TO START (ANYTHING ABOUT CODE).pptx
HOW TO START (ANYTHING ABOUT CODE).pptxssuser62b2da
 
Deccan ruby-conf-talk
Deccan ruby-conf-talkDeccan ruby-conf-talk
Deccan ruby-conf-talkprchaudhari
 
Software development. xp, agile, etc.
Software development. xp, agile, etc.Software development. xp, agile, etc.
Software development. xp, agile, etc.Phil Rukin
 
Programming for non tech entrepreneurs
Programming for non tech entrepreneursProgramming for non tech entrepreneurs
Programming for non tech entrepreneursRodrigo Gil
 
Making sense of the front-end, for PHP developers
Making sense of the front-end, for PHP developersMaking sense of the front-end, for PHP developers
Making sense of the front-end, for PHP developersLewiz
 
React for non techies
React for non techiesReact for non techies
React for non techiesAmy Crimmens
 
Android jetpack compose | Declarative UI
Android jetpack compose | Declarative UI Android jetpack compose | Declarative UI
Android jetpack compose | Declarative UI Ajinkya Saswade
 
SFD 2014: Multiplatform App Development with Migeran
SFD 2014: Multiplatform App Development with MigeranSFD 2014: Multiplatform App Development with Migeran
SFD 2014: Multiplatform App Development with MigeranGergely Kis
 
React for Non Techies
React for Non TechiesReact for Non Techies
React for Non TechiesJack Hoy
 
Introduction to React Native
Introduction to React NativeIntroduction to React Native
Introduction to React NativePolidea
 
On component interface
On component interfaceOn component interface
On component interfaceLaurence Chen
 
Clean Architecture in Android. UPTech TechTalk
Clean Architecture in Android. UPTech TechTalkClean Architecture in Android. UPTech TechTalk
Clean Architecture in Android. UPTech TechTalkHalyna Halkina
 
How to Become a Front-End Developer? Step-by-Step Guide by Careervira
How to Become a Front-End Developer? Step-by-Step Guide by CareerviraHow to Become a Front-End Developer? Step-by-Step Guide by Careervira
How to Become a Front-End Developer? Step-by-Step Guide by CareerviraCareervira
 
Appium an introduction
Appium   an introductionAppium   an introduction
Appium an introductionVivek Shringi
 
Anypoint Code Builder
Anypoint Code BuilderAnypoint Code Builder
Anypoint Code Builderideadocsanjau
 
Website Designing Courses in chandigarh.pptx
Website Designing Courses in chandigarh.pptxWebsite Designing Courses in chandigarh.pptx
Website Designing Courses in chandigarh.pptxSeoDiscovery6
 
From React to React Native - Things I wish I knew when I started
From React to React Native - Things I wish I knew when I startedFrom React to React Native - Things I wish I knew when I started
From React to React Native - Things I wish I knew when I startedsparkfabrik
 
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...dcieslak
 
Software Testing Basic Concepts
Software Testing Basic ConceptsSoftware Testing Basic Concepts
Software Testing Basic Conceptswesovi
 

Similar to Java interfaces design perspective (20)

HOW TO START (ANYTHING ABOUT CODE).pptx
HOW TO START (ANYTHING ABOUT CODE).pptxHOW TO START (ANYTHING ABOUT CODE).pptx
HOW TO START (ANYTHING ABOUT CODE).pptx
 
Deccan ruby-conf-talk
Deccan ruby-conf-talkDeccan ruby-conf-talk
Deccan ruby-conf-talk
 
Software development. xp, agile, etc.
Software development. xp, agile, etc.Software development. xp, agile, etc.
Software development. xp, agile, etc.
 
Programming for non tech entrepreneurs
Programming for non tech entrepreneursProgramming for non tech entrepreneurs
Programming for non tech entrepreneurs
 
Making sense of the front-end, for PHP developers
Making sense of the front-end, for PHP developersMaking sense of the front-end, for PHP developers
Making sense of the front-end, for PHP developers
 
React for non techies
React for non techiesReact for non techies
React for non techies
 
Android jetpack compose | Declarative UI
Android jetpack compose | Declarative UI Android jetpack compose | Declarative UI
Android jetpack compose | Declarative UI
 
SFD 2014: Multiplatform App Development with Migeran
SFD 2014: Multiplatform App Development with MigeranSFD 2014: Multiplatform App Development with Migeran
SFD 2014: Multiplatform App Development with Migeran
 
React for Non Techies
React for Non TechiesReact for Non Techies
React for Non Techies
 
React for non techies
React for non techiesReact for non techies
React for non techies
 
Introduction to React Native
Introduction to React NativeIntroduction to React Native
Introduction to React Native
 
On component interface
On component interfaceOn component interface
On component interface
 
Clean Architecture in Android. UPTech TechTalk
Clean Architecture in Android. UPTech TechTalkClean Architecture in Android. UPTech TechTalk
Clean Architecture in Android. UPTech TechTalk
 
How to Become a Front-End Developer? Step-by-Step Guide by Careervira
How to Become a Front-End Developer? Step-by-Step Guide by CareerviraHow to Become a Front-End Developer? Step-by-Step Guide by Careervira
How to Become a Front-End Developer? Step-by-Step Guide by Careervira
 
Appium an introduction
Appium   an introductionAppium   an introduction
Appium an introduction
 
Anypoint Code Builder
Anypoint Code BuilderAnypoint Code Builder
Anypoint Code Builder
 
Website Designing Courses in chandigarh.pptx
Website Designing Courses in chandigarh.pptxWebsite Designing Courses in chandigarh.pptx
Website Designing Courses in chandigarh.pptx
 
From React to React Native - Things I wish I knew when I started
From React to React Native - Things I wish I knew when I startedFrom React to React Native - Things I wish I knew when I started
From React to React Native - Things I wish I knew when I started
 
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
 
Software Testing Basic Concepts
Software Testing Basic ConceptsSoftware Testing Basic Concepts
Software Testing Basic Concepts
 

Recently uploaded

"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
"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
 
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
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfjimielynbastida
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentationphoebematthew05
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 

Recently uploaded (20)

"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
"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
 
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
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdf
 
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
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentation
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 

Java interfaces design perspective

  • 1. Java Interfaces Design Perspective Chennai Java Summit - 2013 Manigandan Venkataraman shivamanik@gmail.com
  • 2. Agenda ● Application ● Interface – What is an Interface ● Components and Interface ● Java Interface ● Abstraction & Interfaces ● Design Patterns ● Good Design Practices
  • 3. Applications ● Applications that can grow ● Plugins and Addons ● Examples – – ● Application should grow – ● Browser - Firefox IDE – Eclipse, Netbeans Provide plugin/ addon design How to design such an application???
  • 4. Interface ● What is an INTERFACE ● Tell me the interface for this room ● Doors ● Windows ● Interfaces are nothing but communication points ● How do you interface with your Bike or Car ● Interfaces to the Computer ● USB, HDMI, VGA , Serial Ports ● Will this device work with my computer????
  • 7. Operation WebService operation ● ● RMI – Stubs and Skeletons We need Remote Interfaces to compile the local code ● ● Webservice endpoints are interfaces Only interface and NO LOGIC
  • 8. Java Interface ● A way to implement multiple inheritance ● Interface is a collection of abstract methods ● ● now, we can have default implemented methods too .... :) All methods in an interface are public
  • 9. Abstraction ● What does Abstract mean ??? ● I need to go to Mumbai – abstract statement ● Whats missing – – – ● Means of transport Date and time Budget I am travelling to Mumbai on Monday 7 am, by Indigo – Concrete Statement
  • 10. Abstraction ● Your College Project ● Abstract - ???? – – – ● Problem Statement Solution Whats missing - How ??? The Implemention Where's the Implementation – The whole project is the Implementation !!!! ;)
  • 11. Abstraction ● An idea without Implementation ● Why do we need it?? ● Object Oriented Design Interfaces have abstract methods
  • 12. Abstraction and Interfaces ● Runnable Interface ● <Code> ● What it does ● JVM has to deal with unknown code ● Its not aware of Our Code ● Interface Design provides Loose Coupling ● Eclipse Rich Client Platform ● Netbeans Platform
  • 13. Design Patterns ● Mixture of Abstract Classes and Interfaces ● No logic, only provides a guideline/approach ● Upto to programmer to write an implementation – logic
  • 14. Good Design Practices ● Program to an interface , not to implementation ● ● ● Spring Framework Code can grow, more implementations clients remain unaware ● ● ● of the specific types of objects they use, as long as the object adheres to the interface of the classes that implement these objects; clients only know about the abstract class(es) defining the interface Use of an interface also leads to dynamic binding and polymorphism