Exemple #1
0
        protected override void LoadChunk(IntPtr ptr, string type, uint size)
        {
            switch (type)
            {
            case "colh":
                Colh = Marshal.PtrToStructure <CK_COLH>(ptr);
                break;

            case "vers":
                Version = Marshal.PtrToStructure <CK_VERS>(ptr);
                break;

            case "msyn":
                break;

            case "ptbl":
                Ptbl = Marshal.PtrToStructure <CK_PTBL>(ptr);
                break;

            case "DLID":
                break;

            default:
                throw new Exception("[File]Unknown ChunkType");
            }
        }
Exemple #2
0
        protected override void ReadChunk(IntPtr ptr, int chunkSize, string chunkType)
        {
            switch (chunkType)
            {
            case "colh":
                break;

            case "vers":
                mVersion = (CK_VERS)Marshal.PtrToStructure(ptr, typeof(CK_VERS));
                break;

            case "msyn":
                break;

            case "ptbl":
                break;

            case "dlid":
                break;

            default:
                throw new Exception(string.Format("Unknown ChunkType [{0}]", chunkType));
            }
        }