When modeling a virtual circuit board, what is the best design pattern to check for cycles?
To make it simple assume you have only AND and OR gates. Each has two inputs and one output. The output of two inputs can be used as an input for the next gate For example:
What are the differences between abstract classes, interfaces, and when to use them
Recently I have started to wrap my head around OOP, and I am now to the point where the more I read about the differences between abstract classes and interfaces the more confused I become. So far, neither can be instantiated. Interfaces are more or less structural blueprints that determine the skeleton and abstracts are different by being able to partially implement code.
Where should I put a method that returns a list of active entries of a table?
I have a class named GuestbookEntry
that maps to the properties that are in the database table named “guestbook”. Very simple!
Where should I put a method that returns a list of active entries of a table?
I have a class named GuestbookEntry
that maps to the properties that are in the database table named “guestbook”. Very simple!
Strategies for invoking subclass methods on generic objects [duplicate]
Possible Duplicate:
Alternatives to type casting in your domain
REST API wrapper – class design for ‘lite’ object responses
I am writing a class library to serve as a managed .NET wrapper over a REST API. I’m very new to OOP, and this task is an ideal opportunity for me to learn some OOP concepts in a real-life situation that makes sense to me.
Should I use an interface when methods are only similar?
I was posed with the idea of creating an object that checks if a point will collide with a line:
would a composite design pattern be useful for group membership?
I’m trying to think about the best way to handle group memberships on a website. People sign up and select checkboxes in a list of interests. Every week we send out interest-themed emails to those members that indicated that interest.
Do functional generics exist and what is the correct name for them if they do?
Consider the following generic class:
Too complex/too many objects?
I know that this will be a difficult question to answer without context, but hopefully there are at least some good guidelines to share on this. The questions are at the bottom if you want to skip the details. Most are about OOP in general.