Jean-pierre Martineau said:
how implement design pattern in style of object oriented programming in c
?
I think it could be simulate Object oriented by subtitute heritance style
by agregation style.
This group discusses C++. You will find more people familiar with advanced C
style if you post to .
I cross-posted and set the followup to there.
It would seem the important part of design patterns (and of all OO) is
polymorphism. Inheritance and encapsulation are just a framework to
polymorph in.
Classical C polymorphism uses function pointers. So a pattern like Abstract
Template would set a function pointer for each specialized method that the
generic method calls.
This technique is usually called a "callback", and is very common, so OO in
C is probably already very popular.