/Resources.cs

http://geoframework1.codeplex.com · C# · 156 lines · 117 code · 24 blank · 15 comment · 0 complexity · de6834f28e220f203d876617f50041ba MD5 · raw file

  1. using System;
  2. using System.Resources;
  3. using System.Reflection;
  4. using System.Globalization;
  5. namespace GeoFramework
  6. {
  7. /// <summary>
  8. /// Contains United States English resource information.
  9. /// </summary>
  10. internal class Resources
  11. {
  12. // This resource manager will look up the appropriate string based on the current culture. BUT since
  13. // we only have U. S. English resources available, we default to "en-US" resources. In the future, the
  14. // "DefaultCulture" variable will go away and be replaced by CultureInfo.CurrentUICulture.
  15. private static CultureInfo DefaultCulture = new CultureInfo("en-US");
  16. /* ResX files are incompatible between Compact Framework 1.0 and newer versions of the .NET Frameworks because of different "resheader"
  17. * information. As a result, we must maintain two separate ResX files. The naming convention for ResX files is as follows:
  18. *
  19. * Compact Framework 1.0 [Default Namespace].PocketPC.[Culture Name].resx
  20. * All other platforms [Default Namespace].[Culture Name].resx
  21. */
  22. #if Framework30
  23. #if PocketPC
  24. private static ResourceManager resourceManager = new ResourceManager("GeoFramework.Properties.Resources.CF35", typeof(Angle).Assembly);
  25. #else
  26. private static ResourceManager resourceManager = new ResourceManager("GeoFramework.Properties.Resources.DF35", typeof(Angle).Assembly);
  27. #endif
  28. #elif Framework20
  29. #if PocketPC
  30. private static ResourceManager resourceManager = new ResourceManager("GeoFramework.Properties.Resources.CF20", typeof(Angle).Assembly);
  31. #else
  32. private static ResourceManager resourceManager = new ResourceManager("GeoFramework.Properties.Resources.DF20", typeof(Angle).Assembly);
  33. #endif
  34. #elif Framework10
  35. private static ResourceManager resourceManager = new ResourceManager("GeoFramework.Properties.Resources.DF10", typeof(Angle).Assembly);
  36. #else
  37. #if PocketPC
  38. private static ResourceManager resourceManager = new ResourceManager("GeoFramework.Properties.Resources.CF10", typeof(Angle).Assembly);
  39. #else
  40. private static ResourceManager resourceManager = new ResourceManager("GeoFramework.Properties.Resources.DF11", typeof(Angle).Assembly);
  41. #endif
  42. #endif
  43. #if DEBUG
  44. /* This constructor only serves as a convenient way to debug resource problems. Most resource problems occur when a resource is
  45. * called upon but the absolute path to it is incorrect. Verifying the resource name is usually involved in debugging.
  46. */
  47. static Resources()
  48. {
  49. typeof(Resources).Assembly.GetManifestResourceStream("Common_Infinity");
  50. string[] LocalResourceNames = Assembly.GetExecutingAssembly().GetManifestResourceNames();
  51. foreach (string name in LocalResourceNames)
  52. {
  53. Console.WriteLine("Internal resource: " + name);
  54. }
  55. }
  56. #endif
  57. public static readonly string Common_Empty = resourceManager.GetString("Common_Empty");
  58. public static readonly string Common_Infinity = resourceManager.GetString("Common_Infinity");
  59. public static readonly string Angle_TypeMismatch = resourceManager.GetString("Angle_TypeMismatch");
  60. public static readonly string Angle_OnlyRightmostIsDecimal = resourceManager.GetString("Angle_OnlyRightmostIsDecimal");
  61. public static readonly string Angle_ExtraCharactersWereEncountered = resourceManager.GetString("Angle_ExtraCharactersWereEncountered");
  62. public static readonly string Angle_InvalidFormat = resourceManager.GetString("Angle_InvalidFormat");
  63. public static readonly string Angle_InvalidToStringFormat = resourceManager.GetString("Angle_InvalidToStringFormat");
  64. public static readonly string Angle_InvalidInterval = resourceManager.GetString("Angle_InvalidInterval");
  65. public static readonly string Area_InvalidNumericPortion = resourceManager.GetString("Area_InvalidNumericPortion");
  66. public static readonly string Area_InvalidUnitPortion = resourceManager.GetString("Area_InvalidUnitPortion");
  67. public static readonly string Area_InvalidFormat = resourceManager.GetString("Area_InvalidFormat");
  68. public static readonly string Area_ConversionNotImplemented = resourceManager.GetString("Area_ConversionNotImplemented");
  69. public static readonly string Area_InvalidComparisonType = resourceManager.GetString("Area_InvalidComparisonType");
  70. public static readonly string Azimuth_InvalidComparisonType = resourceManager.GetString("Azimuth_InvalidComparisonType");
  71. public static readonly string DoubleBufferedControl_InvalidFramesPerSecond = resourceManager.GetString("DoubleBufferedControl_InvalidFramesPerSecond");
  72. public static readonly string Distance_InvalidNumericPortion = resourceManager.GetString("Distance_InvalidNumericPortion");
  73. public static readonly string Distance_InvalidUnitPortion = resourceManager.GetString("Distance_InvalidUnitPortion");
  74. public static readonly string Distance_InvalidFormat = resourceManager.GetString("Distance_InvalidFormat");
  75. public static readonly string Distance_ConversionNotImplemented = resourceManager.GetString("Distance_ConversionNotImplemented");
  76. public static readonly string Distance_InvalidComparisonType = resourceManager.GetString("Distance_InvalidComparisonType");
  77. public static readonly string RectangleD_InvalidFormat = resourceManager.GetString("RectangleD_InvalidFormat");
  78. public static readonly string SizeD_InvalidFormat = resourceManager.GetString("SizeD_InvalidFormat");
  79. public static readonly string GeoFrameworksLicenseProvider_ExecutionStoppedNeedKeys = resourceManager.GetString("GeoFrameworksLicenseProvider_ExecutionStoppedNeedKeys");
  80. public static readonly string GeoFrameworksLicenseProvider_ExecutionStoppedVisitWebSite = resourceManager.GetString("GeoFrameworksLicenseProvider_ExecutionStoppedVisitWebSite");
  81. public static readonly string GeoFrameworksLicenseProvider_GoOnlineForTrialKeys = resourceManager.GetString("GeoFrameworksLicenseProvider_GoOnlineForTrialKeys");
  82. public static readonly string GeoFrameworksLicenseProvider_LicenseKeyIsRequired = resourceManager.GetString("GeoFrameworksLicenseProvider_LicenseKeyIsRequired");
  83. public static readonly string GeoFrameworksLicenseProvider_LicenseKeyDialogTitle = resourceManager.GetString("GeoFrameworksLicenseProvider_LicenseKeyDialogTitle");
  84. public static readonly string GeoFrameworksLicenseProvider_AskToGoOnline = resourceManager.GetString("GeoFrameworksLicenseProvider_AskToGoOnline");
  85. public static readonly string GeoFrameworksLicenseProvider_ValidTrialLicense = resourceManager.GetString("GeoFrameworksLicenseProvider_ValidTrialLicense");
  86. public static readonly string GeoFrameworksLicenseProvider_ValidOwnerLicense = resourceManager.GetString("GeoFrameworksLicenseProvider_ValidOwnerLicense");
  87. public static readonly string GeoFrameworksLicenseProvider_InvalidLicenseKey = resourceManager.GetString("GeoFrameworksLicenseProvider_InvalidLicenseKey");
  88. public static readonly string GeoFrameworksLicenseProvider_InvalidPlatform = resourceManager.GetString("GeoFrameworksLicenseProvider_InvalidPlatform");
  89. public static readonly string GeoFrameworksLicenseProvider_InvalidMajorVersion = resourceManager.GetString("GeoFrameworksLicenseProvider_InvalidMajorVersion");
  90. public static readonly string GeoFrameworksLicenseProvider_ExecutionStoppedDialogTitle = resourceManager.GetString("GeoFrameworksLicenseProvider_ExecutionStoppedDialogTitle");
  91. public static readonly string GeoFrameworksLicense_InvalidLicenseKey = resourceManager.GetString("GeoFrameworksLicense_InvalidLicenseKey");
  92. public static readonly string TrialLicense_InvalidLicenseKey = resourceManager.GetString("TrialLicense_InvalidLicenseKey");
  93. public static readonly string TrialLicense_LicenseExpired = resourceManager.GetString("TrialLicense_LicenseExpired");
  94. public static readonly string TrialLicense_LicenseExpiredDialogTitle = resourceManager.GetString("TrialLicense_LicenseExpiredDialogTitle");
  95. public static readonly string TrialLicense_ExtendTrial = resourceManager.GetString("TrialLicense_ExtendTrial");
  96. public static readonly string TrialLicense_ExpirationDate = resourceManager.GetString("TrialLicense_ExpirationDate");
  97. public static readonly string GeographicSize_InvalidFormat = resourceManager.GetString("GeographicSize_InvalidFormat");
  98. public static readonly string Latitude_DecimalOrSexagesimalRequired = resourceManager.GetString("Latitude_DecimalOrSexagesimalRequired");
  99. public static readonly string Latitude_ExtraCharactersWereEncountered = resourceManager.GetString("Latitude_ExtraCharactersWereEncountered");
  100. public static readonly string Latitude_LatitudeHemisphereExpected = resourceManager.GetString("Latitude_LatitudeHemisphereExpected");
  101. public static readonly string Latitude_InvalidFormat = resourceManager.GetString("Latitude_InvalidFormat");
  102. public static readonly string Latitude_InvalidHemisphere = resourceManager.GetString("Latitude_InvalidHemisphere");
  103. public static readonly string Latitude_InvalidComparisonType = resourceManager.GetString("Latitude_InvalidComparisonType");
  104. public static readonly string Latitude_OnlyRightmostIsDecimal = resourceManager.GetString("Latitude_OnlyRightmostIsDecimal");
  105. public static readonly string Longitude_DecimalOrSexagesimalRequired = resourceManager.GetString("Longitude_DecimalOrSexagesimalRequired");
  106. public static readonly string Longitude_ExtraCharactersWereEncountered = resourceManager.GetString("Longitude_ExtraCharactersWereEncountered");
  107. public static readonly string Longitude_LongitudeHemisphereExpected = resourceManager.GetString("Longitude_LatitudeHemisphereExpected");
  108. public static readonly string Longitude_InvalidFormat = resourceManager.GetString("Longitude_InvalidFormat");
  109. public static readonly string Longitude_InvalidHemisphere = resourceManager.GetString("Longitude_InvalidHemisphere");
  110. public static readonly string Longitude_InvalidComparisonType = resourceManager.GetString("Longitude_InvalidComparisonType");
  111. public static readonly string Longitude_OnlyRightmostIsDecimal = resourceManager.GetString("Longitude_OnlyRightmostIsDecimal");
  112. public static readonly string Position_InvalidUtmCoordinate = resourceManager.GetString("Position_InvalidUTMCoordinate");
  113. public static readonly string Position_NoUTMZoneNumber = resourceManager.GetString("Position_NoUTMZoneNumber");
  114. public static readonly string Position_NoUTMZoneLetter = resourceManager.GetString("Position_NoUTMZoneLetter");
  115. public static readonly string Position_InvalidZoneLetter = resourceManager.GetString("Position_InvalidZoneLetter");
  116. public static readonly string Position_InvalidZoneNumber = resourceManager.GetString("Position_InvalidZoneNumber");
  117. public static readonly string Position_DuplicateZoneInformation = resourceManager.GetString("Position_DuplicateZoneInformation");
  118. public static readonly string Position_InvalidFormat = resourceManager.GetString("Position_InvalidFormat");
  119. public static readonly string PositionCollection_DistanceError = resourceManager.GetString("PositionCollection_DistanceError");
  120. public static readonly string PositionCollection_AreaError = resourceManager.GetString("PositionCollection_AreaError");
  121. public static readonly string PositionCollection_RangeMustBeAboveZero = resourceManager.GetString("PositionCollection_RangeMustBeAboveZero");
  122. public static readonly string GeographicRectangle_WidthMustBeAboveZero = resourceManager.GetString("GeographicRectangle_WidthMustBeAboveZero");
  123. public static readonly string GeographicRectangle_HeightMustBeAboveZero = resourceManager.GetString("GeographicRectangle_HeightMustBeAboveZero");
  124. public static readonly string Speed_InvalidNumericPortion = resourceManager.GetString("Speed_InvalidNumericPortion");
  125. public static readonly string Speed_InvalidUnitPortion = resourceManager.GetString("Speed_InvalidUnitPortion");
  126. public static readonly string Speed_InvalidFormat = resourceManager.GetString("Speed_InvalidFormat");
  127. public static readonly string Speed_ConversionNotImplemented = resourceManager.GetString("Speed_ConversionNotImplemented");
  128. public static readonly string Speed_InvalidComparisonType = resourceManager.GetString("Speed_InvalidComparisonType");
  129. public static readonly string ThreadPool_InvalidMaximumThreads = resourceManager.GetString("ThreadPool_InvalidMaximumThreads");
  130. public static readonly string ThreadPool_InvalidMaximumQueueSize = resourceManager.GetString("ThreadPool_InvalidMaximumQueueSize");
  131. }
  132. }