The Labs \ Source Viewer \ SSCLI \ System.Globalization \ CultureTableHeader

  1. // ==++==
  2. //
  3. //
  4. // Copyright (c) 2006 Microsoft Corporation. All rights reserved.
  5. //
  6. // The use and distribution terms for this software are contained in the file
  7. // named license.txt, which can be found in the root of this distribution.
  8. // By using this software in any fashion, you are agreeing to be bound by the
  9. // terms of this license.
  10. //
  11. // You must not remove this notice, or any other, from this software.
  12. //
  13. //
  14. // ==--==
  15. // The file is autogenerated by nlpgen.pl.
  16. // DO NOT EDIT THIS FILE MANUALLY.
  17. // DO NOT EDIT THIS FILE MANUALLY.
  18. // DO NOT EDIT THIS FILE MANUALLY.
  19. namespace System.Globalization
  20. {
  21.     using System.Runtime.InteropServices;
  22.    
  23.     ////////////////////////////////////////////////////////////////////////
  24.     //
  25.     // This header is in the beginning of the data table, and it contains offset
  26.     // which point to little-Endian and big-Endian versions of the real header
  27.     // (BaseInfoHeader) and the headers will contain offset to different data
  28.     // of little-Endian and big-Endian.
  29.     //
  30.     ////////////////////////////////////////////////////////////////////////
  31.    
  32.     // StructLayout is needed here otherwise compiler can re-arrange the fields.
  33.     [StructLayout(LayoutKind.Sequential, Pack = 2)]
  34.     internal struct EndianessHeader
  35.     {
  36.         internal uint leOffset;
  37.         // DWORD: The offset (from the beginning of the file) to LE BaseInfoHeader. This might be a value of 0 if one version is in the table.
  38.         internal uint beOffset;
  39.         // DWORD: The offset (from the beginning of the file) to BE BaseInfoHeader. This might be a value of 0 if one version is in the table.
  40.     }
  41.    
  42.     //
  43.     //
  44.     //
  45.    
  46.     [StructLayout(LayoutKind.Sequential, Pack = 2)]
  47.     internal struct CultureTableHeader
  48.     {
  49.         // Generic header information
  50.         internal uint version;
  51.         // DWORD version
  52.         internal ushort hash0;
  53.         // WORD[8]
  54.         internal ushort hash1;
  55.         internal ushort hash2;
  56.         internal ushort hash3;
  57.         internal ushort hash4;
  58.         internal ushort hash5;
  59.         internal ushort hash6;
  60.         internal ushort hash7;
  61.         internal ushort headerSize;
  62.         // WORD: The size of the header ((bytes) irrelevent right now because all of our sections have offsets)
  63.         // Culture Table Data
  64.         internal ushort numLcidItems;
  65.         // WORD: The number of items in the LCID index.
  66.         internal ushort numCultureItems;
  67.         // WORD: The number of culture data items in the table.
  68.         internal ushort sizeCultureItem;
  69.         // WORD: The total size of each culture data item (bytes)
  70.         internal uint offsetToCultureItemData;
  71.         // DWORD: The offset (from the beginning of the file) to the culture data items (bytes).
  72.         // Culture Table Indexing Data
  73.         internal ushort numCultureNames;
  74.         // WORD: The number of items in culture name index table.
  75.         internal ushort numRegionNames;
  76.         // WORD: The number of items in region name index table.
  77.         internal uint cultureIDTableOffset;
  78.         // DWORD: Offset (in bytes) to Culture LCID Offset Table. The offset is related to the beginning of the file (in bytes).
  79.         internal uint cultureNameTableOffset;
  80.         // DWORD: Offset (in bytes) to Culture Name (en-us) Offset Table. The offset is related to the beginning of the file (bytes).
  81.         internal uint regionNameTableOffset;
  82.         // DWORD: Offset (in bytes) to Region Name (us) Offset Table. The offset is related to the beginning of the file (bytes).
  83.         // Calendar Table Data
  84.         internal ushort numCalendarItems;
  85.         // WORD: The number of calendar data items in the table.
  86.         internal ushort sizeCalendarItem;
  87.         // WORD: The total size of each calendar data item (bytes)
  88.         internal uint offsetToCalendarItemData;
  89.         // DWORD: The offset (from the beginning of the file) to the calendar data items (bytes).
  90.         // Data Pool
  91.         internal uint offsetToDataPool;
  92.         // DWORD: Offset (bytes) to the Data Pool (for strings, etc.)
  93.         // Ietf Name Index
  94.         internal ushort numIetfNames;
  95.         // WORD: The number of IETF names in the IETF name index table.
  96.         internal ushort Unused_Padding;
  97.         // WORD: Keep it short aligned.
  98.         internal uint ietfNameTableOffset;
  99.         // DWORD: Offset (in bytes) to the ietf name Offset Table
  100.     }
  101.    
  102. }

Developer Fusion