add a Cloneable class.
update Composite.

If we use a boost prt container to store the components,
when we new a object, and before we add this to the
container, a exception is thrown, there will be memory
leak.
the solution is use a boost shared ptr to hold the
pointer.