void Start()
    {
        Debug.Log("-----------------<1>-----------------");

        MonsterDataV1 dataV1 = new MonsterDataV1()
        {
            Name     = "スライム",
            HitPoint = 10,
            HitRate  = 80f,
            Speed    = 2,
            Luck     = 3,
        };

        {
            byte[]        bytes    = ZeroFormatterSerializer.Serialize(dataV1);
            MonsterDataV1 loadData = ZeroFormatterSerializer.Deserialize <MonsterDataV1>(bytes);

            Debug.Log("Name:" + loadData.Name);
            Debug.Log("HitPoint:" + loadData.HitPoint);
            Debug.Log("HitRate:" + loadData.HitRate);
            Debug.Log("Speed:" + loadData.Speed);
            Debug.Log("Luck:" + loadData.Luck);
        }

        Debug.Log("-----------------<2>-----------------");

        MonsterDataV2 dataV2 = new MonsterDataV2()
        {
            Name     = "スライムベッキー",
            HitPoint = 100,
            HitRate  = 95f,
            Speed    = 200,
            Luck     = 300,
            Defense  = 400,
        };

        {
            byte[]        bytes    = ZeroFormatterSerializer.Serialize(dataV2);
            MonsterDataV2 loadData = ZeroFormatterSerializer.Deserialize <MonsterDataV2>(bytes);

            Debug.Log("Name:" + loadData.Name);
            Debug.Log("HitPoint:" + loadData.HitPoint);
            Debug.Log("HitRate:" + loadData.HitRate);
            Debug.Log("Speed:" + loadData.Speed);
            Debug.Log("Luck:" + loadData.Luck);
            Debug.Log("Defense:" + loadData.Defense);
        }

        Debug.Log("-----------------<3>-----------------");

        PackAndUnpack(dataV1);

        Debug.Log("-----------------<4>-----------------");

        PackAndUnpack(dataV2);
    }
    void OutputToLog(MonsterDataBase data)
    {
        switch (data.Version)
        {
        case MonsterDataBase.VersionType.MonsterDataV1:
            MonsterDataV1 version1 = data as MonsterDataV1;
            Debug.Log("Name:" + version1.Name);
            Debug.Log("HitPoint:" + version1.HitPoint);
            Debug.Log("HitRate:" + version1.HitRate);
            Debug.Log("Speed:" + version1.Speed);
            Debug.Log("Luck:" + version1.Luck);
            break;

        case MonsterDataBase.VersionType.MonsterDataV2:
            MonsterDataV2 version2 = data as MonsterDataV2;
            Debug.Log("Name:" + version2.Name);
            Debug.Log("HitPoint:" + version2.HitPoint);
            Debug.Log("HitRate:" + version2.HitRate);
            Debug.Log("Speed:" + version2.Speed);
            Debug.Log("Luck:" + version2.Luck);
            Debug.Log("Defense:" + version2.Defense);
            break;
        }
    }
        void TestZeroFormatter()
        {
            Stopwatch stopWatch = new Stopwatch();

            string name     = null;
            uint   hitPoint = 0;
            float  hitRate  = 0f;
            uint   speed    = 0;
            uint   luck     = 0;

            string path = Path.Combine(Application.persistentDataPath, ZERO_FORMATTER_FILE_NAME);

            //UnityEngine.Debug.Log("path:" + path);

            if (File.Exists(path))
            {
                File.Delete(path);
            }

            stopWatch.Start();

            for (int i = 0; i < COUNT; ++i)
            {
                // 読み込み
                if (File.Exists(path))
                {
                    MonsterDataBase dataBase = ZeroFormatterSerializer.Deserialize <MonsterDataBase>(File.ReadAllBytes(path));

                    switch (dataBase.Version)
                    {
                    case MonsterDataBase.VersionType.MonsterDataV1:
                    {
                        MonsterDataV1 data = dataBase as MonsterDataV1;
                        name     = data.Name;
                        hitPoint = data.HitPoint;
                        hitRate  = data.HitRate;
                        speed    = data.Speed;
                        luck     = data.Luck;
                        //UnityEngine.Debug.Log("[ZeroFormatter] Data load. hitPoint:" + hitPoint);
                        break;
                    }
                    }
                }

                hitPoint++;
                hitRate += 1f;
                speed++;
                luck++;

                // 書き込み
                {
                    MonsterDataV1 data = new MonsterDataV1()
                    {
                        Name     = MONSTER_NAME,
                        HitPoint = hitPoint,
                        HitRate  = hitRate,
                        Speed    = speed,
                        Luck     = luck,
                    };

                    UnityEngine.Debug.Log("[ZeroFormatter] data:" + data);
                    File.WriteAllBytes(path, ZeroFormatterSerializer.Serialize <MonsterDataBase>(data));
                }

                //UnityEngine.Debug.Log("[ZeroFormatter] hitPoint:" + hitPoint);

                hitPoint = 0;
            }

            stopWatch.Stop();
            _zeroFormatterElapsedTime = stopWatch.ElapsedMilliseconds;
        }