~cpp
class TeXCompositor : public Compositor {
public:
TeXCompositor ();
virtual int Compose (
Coord natural[], Coord stretch[], Coord shrink[],
int componmentCount, int lineWidth, int breaks[]
);
// ...
};
{{{~cpp
class ArrayCompositor : public Compositor {
public:
ArrayCompositor (int interval);
virtual int Compose (
Coord natural[], Coord stretch[], Coord shrink[],
int componentCount, int lineWidth, int breaks[]
);
// ...
};
{{{~cpp
Composition* quick = new Composition (new SimpleCompositor);
Composition* slick = new Composition (new TeXCompositor);
Composition* iconic = new Composition (new ArrayCompositior (100));
}}}
== Known Uses ==
* ET++, InterViews - line breaking algorithms as we've described.
* RTL System for compiler code optimization - Register allocation, Instruction set Scheduling.
* ET++ SwapsManager cacluation engine framework.
* The Booch components - template arguments. - memory allocation strategies.
* RApp (system for integrated circult layout) - Router Algorithms.
* Borland's ObjectWindows - dialog box. validation streategies.
== Releated Patterns ==
FlyWeightPattern : Strategy 객체는 종종 훌륭한 flyweight를 만든다.
----
["패턴분류"]