Power of interfaces in Software Development

What are interfaces?

Why Interfaces?

  • They provide a layer of abstraction that keeps the detailed implementation hidden from the user. Users of the interface can trust it to function as per the contact without worrying about the underneath implementation.
  • Single interface declaration can have multiple implementations underneath utilizing a varied set of vendors or a different logic serving the same use case in different flavors.
  • Maintaining backward compatibility is easier as the contract established through interfaces remains unchanged while the implementation underneath is enhanced.
  • Interfaces enable Test-Driven Development (TDD). In absence of any implementation, interface declarations can be used to generate mocks that help in writing the tests.

--

--

--

Software Engineer @Virtana

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Creating GIFs from MRI Scans (nii.gz)

A full-featured multi-tenant app with Laravel Part 2 — Roles and Permissions

Minimize the Jobs in your GitLab CI Pipeline

MEVerse Updates on 4th Mar 2022

When is structure used?

A WFS 3.0 prototype in GeoServer; are we getting it right?

UpBots Weekly Wrap up: Platform updates, SuperBots and Metaverse

Abstract Factory in Typescript (GoF Design Pattern)

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Sumit Salvi

Sumit Salvi

Software Engineer @Virtana

More from Medium

Technical debt in eCommerce — a silent killer of the revenue — BitBag

The best line of code is the one that was never written

How to Upload Flutter Project on GitHub | Bring Remote Repo Locally | A — Z | 2022

Websocket rooms: Horizontal scaling architectures