Hi all,
Repeating design patterns I decided to create examples of their implementation for (x)Harbour.
First two patterns.
Facade pattern:
http://code.google.com/p/santysoft/down ... akechanges
Mediator pattern:
http://code.google.com/p/santysoft/down ... akechanges
to be continued.
Design patterns for (x)harbour
Moderator: Rathinagiri
Design patterns for (x)harbour
Best regards,
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Re: Design patterns for (x)harbour
Best regards,
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Re: Design patterns for (x)harbour
Builder pattern
http://code.google.com/p/santysoft/down ... akechanges
Two simple example using this pattern (in archive):
Computer builder and Report Builder.
to be continued.
http://code.google.com/p/santysoft/down ... akechanges
Two simple example using this pattern (in archive):
Computer builder and Report Builder.
to be continued.
Best regards,
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Re: Design patterns for (x)harbour
Template method pattern
Intent. Define the skeleton of an algorithm in an operation, deferring some steps to subclasses. Template Method lets subclasses redefine certain steps of an algorithm without changing the algorithm's structure
http://code.google.com/p/santysoft/down ... akechanges
to be continued.
Intent. Define the skeleton of an algorithm in an operation, deferring some steps to subclasses. Template Method lets subclasses redefine certain steps of an algorithm without changing the algorithm's structure
http://code.google.com/p/santysoft/down ... akechanges
to be continued.
Best regards,
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Re: Design patterns for (x)harbour
Decorator pattern
Intent. Attach additional responsibilities to an object dynamically. Decorators provide a flexible
alternative to subclassing for extending functionality.
http://code.google.com/p/santysoft/down ... akechanges
Factory Method pattern
Intent. Define an interface for creating an object, but let subclasses decide which class to
instantiate. Factory Method lets a class defer instantiation to subclasses.
http://code.google.com/p/santysoft/down ... akechanges
Intent. Attach additional responsibilities to an object dynamically. Decorators provide a flexible
alternative to subclassing for extending functionality.
http://code.google.com/p/santysoft/down ... akechanges
Factory Method pattern
Intent. Define an interface for creating an object, but let subclasses decide which class to
instantiate. Factory Method lets a class defer instantiation to subclasses.
http://code.google.com/p/santysoft/down ... akechanges
Best regards,
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Re: Design patterns for (x)harbour
Prototype pattern
Intent. Specify the kinds of objects to create using a prototypical instance, and create new objects by
copying this prototype
http://code.google.com/p/santysoft/down ... r&can=2&q=
to be continued
Intent. Specify the kinds of objects to create using a prototypical instance, and create new objects by
copying this prototype
http://code.google.com/p/santysoft/down ... r&can=2&q=
to be continued
Best regards,
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko
Oleksandr Antypenko
xHarbour 1.2.3 , Harbour 3.x + Mingw 4.x (HMG, minigui)
https://bitbucket.org/aantypenko
https://github.com/aantypenko