Relative Content

Tag Archive for interfaces

What problems will I face if I remove the concept of interfaces from my code?

I have been programming for many years but I am still not comfortable with the concept of “Interfaces”. I try to use interfaces but many times I don’t see a mandatory use for it. I think this is probably because the projects weren’t so big, or because interfaces are more useful when teamwork is involved.

Switch interface implementation using configuration [closed]

It’s difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 11 years ago. We want to allow the same core service […]

Can a common interface be defined for Cartesian and Polar coordinate data?

I’m rewriting a set of file readers that a former-colleague of mine created that read raw-point data of XYZ (Cartesian) coordinates or RTZ (Polar) coordinates. Currently the data is stored directly in the reader, making everything rely on the state of those objects. I’d like to separate the reader from the collected data it reads by creating some data objects.

Class inheritance and extra parameters

Im trying to create an SMS gateway .. I have a request coming in from a client (web form or API or database record) that I need to process and forward on to a 3rd Party API – or SMS provider. So that things would be simpler going forward I decided to create an interface that each provider implementation would implement :