/**
 * 最初の著者:: トゥイー
 * リポジトリ情報:: $Id: UnificatedAttributes.hpp 11 2011-05-14 02:11:18Z yutaka_at_home $
 * 著作権:: Copyright (C) Ownway.info, 2011. All rights reserved.
 * ライセンス:: CPL(Common Public Licence)
 */

#ifndef _TOPS_UNIFICATED_ATTRIBUTES_
#define _TOPS_UNIFICATED_ATTRIBUTES_

#include <list>

#include <boost/shared_ptr.hpp>

namespace tops {

	class AttributeOfFact;

	class UnificatedAttributes;
	typedef boost::shared_ptr<UnificatedAttributes> UnificatedAttributesPtr;

	/**
	 * 単一化済み属性列です。
	 *
	 * @author トゥイー
	 */
	class UnificatedAttributes {
	private:
		typedef std::list<AttributeOfFact*> AttributeContainer;

		AttributeContainer m_attributes;

	public:
		typedef AttributeContainer::iterator iterator;
		typedef AttributeContainer::const_iterator const_iterator;

	public:
		iterator begin() {
			return m_attributes.begin();
		}

		const_iterator begin() const {
			return m_attributes.begin();
		}

		iterator end() {
			return m_attributes.end();
		}

		const_iterator end() const {
			return m_attributes.end();
		}

	public:
		void add(AttributeOfFact& attribute);
	};

}  // namespace tops

#endif
