All Questions
Tagged with inheritance interface
18
questions
5
votes
2answers
407 views
Best approach for the Design Pattern for multiple schedulers using interface and abstract class
I have a requirement to fetch data for different types of Users (Customers, Publishers etc) for three different timelines (retro, current, and past), all have different URLs. There is a scheduler ...
3
votes
1answer
247 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....
2
votes
1answer
97 views
Interface and inheritance; creating download types for a download manager
I'm creating a download manager in C# (in combination with Unity 2019.1.8, running the .NET 4.x equivalent (MONO) scripting back end). To accomplish this I decided to start using interfaces and class ...
1
vote
1answer
44 views
Proper naming for objects which have a position and bounds on a plane
I have an interface which is for an object which has bounds in a 2D plane.
...
3
votes
3answers
3k views
OOP modelling of a car agency
Exercise:
A car dealer wants a computer system to manage the data of their vehicles and classify them by type.
All cars have the following data
Engine serial number
Brand
Year
...
9
votes
1answer
2k views
OOP modeling of a boat rental system
I have some question about this exercise, did I model the problem correctly (the code works)?. If I did it correctly, Is there anything that can improve the code?. For example, how could I avoid the ...
-2
votes
1answer
225 views
Parsing various types of message strings
Similar question
MessageFormat: represents the various kinds of messages. (XML, JSON, ...
1
vote
1answer
28 views
Multiple Interfaces modifying contract
I have a problem with my interface-design. I especially ask for help with the overloaded compute-Method.
For a calculator I work with these Interfaces:
...
2
votes
2answers
87 views
Represent a person who has different roles for different offices
People have different types of roles depending on the office they are working at. For example, a person has two roles (cashier,cleaner) at OfficeMax and five roles(manager,security,etc) at OfficeLess. ...
3
votes
1answer
2k views
Classes representing items in an RPG game
I wrote a little program in C# that contains classes representing Items in RPG game. I wanted to have access to all inherited classes parameters from list contains parent Item class instances, so this ...
0
votes
2answers
219 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 ...
1
vote
1answer
1k views
Document (PDF, TXT, DOCX) to text classes
I wrote some classes to convert some documents (PDF, DOC, DOCX and TXT) to only text so that it can be stored in a search engine.
Here's how I use those classes :
...
14
votes
4answers
2k views
Reusability vs simplicity in a small game with a set of interfaces
I have a small game I'm working on with a set of interfaces:
IHavePosition:
...
2
votes
1answer
192 views
Many interfaces and lots of inheritance vs few interfaces and less inheritance? [closed]
I have a Visual Studio Solution which has a bunch of Projects in it. One of these projects is called "Services" and is basically the junction point between all remaining projects. When I built it ...
5
votes
2answers
181 views
Interface for a transformable grid
I am working on an XNA project, and since procedural generation is likely to be used, I wanted to eventually create a helper class to work with data to facilitate that.
Design Goal:
Originally, I ...
12
votes
1answer
190 views
DataLayer Interfaces Genericized
I have some concerns on my refactoring for the data layer in my current Project. Just for a small info, I am currently building a CRM as "training JEE application". But enough of talk, let's talk code!...
3
votes
1answer
2k views
How to deal with interface inheritance and common properties? [closed]
I'm trying to design a generic caching system that takes keyed items and allows either read-only or read-write access to a cached version of it. The read-only backing interface is:
...
6
votes
4answers
16k views
Understanding interface with animal classes
I made this small program to demonstrate to myself an example of interface. I wanted to confirm whether it is correct and if there is anything more I should know about interfaces other than the ...