#ifndef CHAIN_GROUP_IMPL_H
#define CHAIN_GROUP_IMPL_H

#ifndef CHAIN_GROUP_H
#include "Chain_group.h"
#endif

#ifndef CHAIN_H
#include "Chain.h"
#endif

#ifndef ARRAY_OF_OWN_H
#include "Array_of_own.h"
#endif

namespace MM
{

class Chain_group_impl : public Chain_group
{
    Array_of_own <Chain>    group_;

public:
    virtual int             chain_count () const    {return group_.size();}
    virtual Chain &         chain (int i)           {return group_[i];}
    virtual Chain const &   chain (int i) const     {return group_[i];}
    virtual void            adopt (Chain * adoptee) {group_.adopt (adoptee);}
    virtual Chain *         orphan(Chain & chain) {return group_.orphan(chain);}
};

}//MM
#endif //CHAIN_GROUP_IMPL_H
