We’re rewarding the question askers & reputations are being recalculated! Read more.

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.

Filter by
Sorted by
Tagged with
1
vote
0answers
874 views

Interface for Dapper repository

I'm creating a little proposal for the data access layer using Dapper ORM. The code is based in an generic interface IStore: ...
1
vote
0answers
52 views

A generic interface for nearest-neighbor data structures

I have written the following interface to represent data structures such as VP trees that perform nearest-neighbor searches. ...
1
vote
0answers
73 views

Is this interface structure/setup correct?

I'm working on wrapping the last.fm web API. I'm trying to use Interfaces to be able to easily make calls via functions which return an interface (as opposed to an object which would need to be free'd)...
0
votes
4answers
97 views

iOS SDK object to represent a place

I am building an iOS SDK to be consumed by apps. I am building an object that represents a physical place. The interface looks like so: ...
0
votes
1answer
81 views

Different implementation of an Interface along with additional parameters

I am designing an interface for 2 distinct implementations as follows: Perform operations without client credentials ( for my local applications) Perform operations using security token. (for web ...
0
votes
2answers
4k views

Safe DbContext Disposal

I have a service class called ClientService, the service class is called using an interface IClientService. The service class ...
0
votes
1answer
44 views

proper structure of classes using interface classes [closed]

Given the following two interfaces what would the proper way to set up the two actual classes? ...
0
votes
2answers
80 views

Have a class that holds all the interfaces [closed]

I seriously didn't know how to write this in Google, there must be an answer lying around. Here it goes: I'm using Ninject (IoC) and ASP.NET MVC 5. I have a business layer with a couple of classes. ...
0
votes
2answers
192 views

Very complicated Java HelloWorld app

This program attempts to shows the basic concepts of inheritance and polymorphism. In what ways could the code be modified to better demonstrate those concepts? The interface, abstract class and the ...
0
votes
2answers
76 views

Would you utilise “Using” on a member which is going to be added to a list? [closed]

I have an interface and a concrete class which I am using in the code below: ...
0
votes
1answer
78 views

Functional List in C++ [closed]

This is rather toy example of immutable datatype in C++. I've tried to follow functional languages like Scheme, Racket - making list as a cons cell: list is list or is empty. ...
0
votes
1answer
59 views

Using a wrapper on a primitive as a generic for an interface used for Java lambda

I apologize for that title, lol. I have a Java method that I'm writing where I want to be able to pass in an array of Objects and two interfaces that will be used for lambda expressions that specify ...
0
votes
1answer
27 views

interface design for allowing custom parameter struct, falling back on defaults

Right now I have an awkward setup, but don't really know what the cleaner solution would look like. The parameter struct is defining the action keys for a simple fly camera. Right now it looks like ...
0
votes
2answers
106 views

Is this code a good solution for this task?

...
0
votes
1answer
984 views

ViewModel class in Typescript

I am trying to refactor a ViewModel class because it has two methods that are really similar called updateRegions and ...
0
votes
1answer
72 views

Wrapping packet information [closed]

I am developing a network application and therefor need to specify the packets I want to send. I have a basic interfaces class and one for the packets that implement them. ...
0
votes
1answer
2k views

Polymorphic template cloning class

I have a requirement of a templated clone() method which Base classes can implement through an ICloneable interface and all the ...
0
votes
3answers
81 views

“Human” interfaces with two implementation classes

The Helloworld class executes all of the methods. Human is the interface, and Nate & <...
-1
votes
1answer
46 views

An interface for designing Arduino code [closed]

Writing code could be divided into three parts. 1.Interface structure At this stage programmer should describe all the devices used in his project. Of course, only those of them which Arduino ...
-2
votes
1answer
220 views

Parsing various types of message strings

Similar question MessageFormat: represents the various kinds of messages. (XML, JSON, ...