00001 #ifndef STATIC_CONTAINER_LIST_HASH_H 00002 00003 #define STATIC_CONTAINER_LIST_HASH_H 00004 00005 /* 00006 zlib/libpng license 00007 ------------------- 00008 00009 Copyright (C) 2004 &o 00010 00011 This software is provided 'as-is', without any express or implied warranty. In n 00012 o event will the authors be held liable for any damages arising from the use of 00013 this software. 00014 00015 Permission is granted to anyone to use this software for any purpose, including 00016 commercial applications, and to alter it and redistribute it freely, subject to 00017 the following restrictions: 00018 00019 The origin of this software must not be misrepresented; you must not claim that 00020 you wrote the original software. If you use this software in a product, an ackno 00021 wledgment in the product documentation would be appreciated but is not required. 00022 00023 Altered source versions must be plainly marked as such, and must not be misrepre 00024 sented as being the original software. 00025 This notice may not be removed or altered from any source distribution. 00026 00027 project site : https://sourceforge.jp/projects/gslib/ 00028 my site : http://www.game-syokunin.com/ 00029 -------------------------------------------------------------------------------- 00030 00031 法的には、上記の原文のほうが有効なので、より厳密には日本語訳よりも原文を参考にし 00032 てください。日本語訳は、http://opensource.jp/licenses/zlib-license.html から頂い 00033 てきました。 00034 00035 zlib/libpngライセンス ( 日本語訳 ) 00036 00037 Copyright (C) 2004 &o 00038 00039 本ソフトウェアは「現状のまま」で、明示であるか暗黙であるかを問わず、何らの保証も 00040 なく提供されます。本ソフトウェアの使用によって生じるいかなる損害についても、作者 00041 は一切の責任を負わないものとします。 以下の制限に従う限り、商用アプリケーション 00042 を含めて、本ソフトウェアを任意の目的に使用し、自由に改変して再頒布することをすべ 00043 ての人に許可します。 00044 00045 本ソフトウェアの出自について虚偽の表示をしてはなりません。あなたがオリジナルのソ 00046 フトウェアを作成したと主張してはなりません。あなたが本ソフトウェアを製品内で使用 00047 する場合、製品の文書に謝辞をれていただければ幸いですが、必須ではありません。 00048 ソースを変更した場合は、そのことを明示しなければなりません。オリジナルのソフトウ 00049 ェアであるという虚偽の表示をしてはなりません。 00050 ソースの頒布物から、この表示を削除したり、表示の内容を変更したりしてはなりません 00051 。 00052 00053 project site : https://sourceforge.jp/projects/gslib/ 00054 my site : http://www.game-syokunin.com/ 00055 */ 00056 00057 #include <gslib/static_container/hash.h> 00058 #include <gslib/static_container/list.h> 00059 00060 namespace gslib { 00061 namespace static_container { 00063 template < typename Key, typename Value, size_t MaxSize, typename KeyEqual = std::equal_to< Key > > 00064 class list_hash : public hash< Key, Value, list< std::pair< Key, Value >, MaxSize >, KeyEqual > { 00065 public: 00066 typedef hash< Key, Value, list< std::pair< Key, Value >, MaxSize >, KeyEqual > parent; 00067 00068 typedef typename parent::value_type value_type; 00069 typedef typename parent::reference reference; 00070 typedef typename parent::const_reference const_reference; 00071 typedef typename parent::iterator iterator; 00072 typedef typename parent::const_iterator const_iterator; 00073 typedef typename parent::size_type size_type; 00074 00075 list_hash( key_equal equal = KeyEqual() ) : parent( equal ) {} 00076 }; 00077 } 00078 } 00079 00080 #endif