Is Liskov Substitution Principle incompatible with Introspection or Duck Typing?
Do I understand correctly that Liskov Substitution Principle cannot be observed in languages where objects can inspect themselves, like what is usual in duck typed languages?
What are the practical ways to implement the SRP?
Simply what are the practical techniques people use to check if a class violates the single responsibility principle?
Template rendering engine legitimate use of a singleton?
I wrote a standalone singleton class (scaffold) tonight that serves as a facade to a few other classes, including a template class and a view class. Templates and views are both named and instances of each are stored in the scaffold object. Templates can contain views and views can contain other views. A template and it’s contained views is rendered when:
How to deal with hints/tutorial mode?
Currently I’m working on an basic application that has a ‘tutorial mode’. Initially hints (bubbles with text) will be displayed above various ui elements, explaining how they work. Currently I have a main view which contains a hint object that can be updated (position, text, etc.) and I’m dispatching update events from the various views that need to display a hint. In most cases when the user click a hint, it disappears, but there are a few situations when the user must perform another action(like dragging-dropping an element, clicking another,etc.) to progress.
How to represent association in programs [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 12 years ago. Could someone help me in implementing association in […]
Inheritance using non-abstract base class
This post is based on the question https://stackoverflow.com/questions/49002/prefer-composition-over-inheritance/11758048#comment15634305_11758048.
Pattern(s) about hierarchical settings overwriting
Assume that you have a hierarchy of organizational units:
Implenting ActiveRecord with inheritance?
I recently converted an old application that was using XML files as the data store to use SQL instead. To avoid a lot of changes I basically created ActiveRecord style classes that inherited from the original business objects.
Generating different combinations from a list of muscles
Suppose we have a model of a human muscular system containing the following muscles each within a specific muscle group:
Make use of design patterns in C? [closed]
Closed 10 years ago.