Skip to main content

Questions tagged [interface]

Object interfaces allow you to create code which specifies which methods a class must implement, without having to define how these methods are handled.

0 votes
1 answer
447 views

Composing functionality of sealed class with interfaces

...
JPtheK9's user avatar
  • 103
4 votes
1 answer
2k views

multiple inheritance in c++ to implement different interfaces

I am working on a finite element (FE) code and want to provide multiple material models (20+). In FE applications, the computational domain is subdivided into a set of geometrically simple elements, e....
StefanKssmr's user avatar
0 votes
3 answers
251 views

Using "Generics" to implement "Unit Of Work"

I need to design a generic "Unit Of Work", basically so that I can "change the context of the Database" only changing the implementation of ...
Igor's user avatar
  • 182
7 votes
4 answers
1k views

IService<T> or defining IProductService, ICustomerService

As per tutorial here, I have the following classes: (In reference to this tutorial's section) ...
taylorswiftfan's user avatar
7 votes
2 answers
146 views

Refactoring validator system

I've validator system that validates input data before saving to DB. So let's say I want to create new user. We are at the service class: ...
makiz1234's user avatar
3 votes
3 answers
584 views

Returning interfaces in Java without significant casting

I am writing some code that takes and returns interfaces following the patterns in Effective Java Third Edition. I understand the principle - we want to take in interfaces because in many cases we don'...
CL40's user avatar
  • 133
4 votes
1 answer
1k views

Interface class for SQLite databases

I am learning the basics about managing an SQLite database by using Python and, mainly for practice purposes, I have then defined an interface class in order to let operations on database as clear as ...
rudicangiotti's user avatar
1 vote
0 answers
65 views

Code for creating a dialog for choosing a date

I have code that creates an AlertDialog to select a date by a user. I ran into a problem that this code began to take up a lot of space. Could you offer ideas on how to shorten this code / put it into ...
Destroyer's user avatar
  • 477
-2 votes
1 answer
624 views

C++ generic task interface for delayed execution

I want to rework my current game-server engine to use some global queue of tasks which will be distributed through all the working threads. I started with task interface. I want it to be able to ...
Piodo's user avatar
  • 97
1 vote
1 answer
2k views

Should Golang interface be shared among different packages of an application?

I'm developing a Go application that has lots of packages. Many of the packages use the same type from a 3rd party library. Should an interface be defined for the type in each package, and let the ...
Hans's user avatar
  • 29
4 votes
1 answer
184 views

Architecture Logging

I have two database tables UsersDownload, Non-UsersDownload. There is also two model object and two service that take in the object and insert the data into the correct table. Is this the best ...
Jefferson's user avatar
  • 353
0 votes
1 answer
67 views

Schedule talks in tracks [closed]

Consider my simple business requirement as follows: There is a list of talks and they need to be scheduled in tracks. Each track has a morning session starting at 9am and an afternoon session starting ...
riki's user avatar
  • 109
3 votes
1 answer
902 views

C# REST / Http Client Abstraction

I have a REST library. These are the abstractions. Have I missed anything that a developer would need to use this in a dependency injection / IoC Container scenario? Anything that bothers you about ...
Christian Findlay's user avatar
4 votes
0 answers
336 views

C# Dictionary Wrapper for VBA

I am a technical reviewer/writer and I use VBA for Word a lot to manage issues in Word documents I receive. I have frequently come across niggles when using Collections, Scripting.Dictionaries or ...
Freeflow's user avatar
  • 645
6 votes
2 answers
264 views

Opposite access to enums

Consider I have many enums (Java) that looks somewhat like this: ...
Hallel's user avatar
  • 163

15 30 50 per page
1
2
3 4 5
13