FileDescription.h 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. #pragma once
  2. #include "ThirdPartyHeadersBegin.h"
  3. #include <string>
  4. #include "ThirdPartyHeadersEnd.h"
  5. #include "IJK.h"
  6. #include "fileStuff.h"
  7. #include "SzlFileLoader.h"
  8. namespace tecplot
  9. {
  10. namespace ___3933
  11. {
  12. class ___1388
  13. {
  14. public:
  15. static inline bool validIsAscii(___372 ___2002) { return VALID_BOOLEAN(___2002); };
  16. static inline bool validDataFileType(DataFileType_e ___844) { return VALID_ENUM(___844, DataFileType_e); }
  17. static inline bool validIJKSubzoneSize(___1844 const &ijkSubzoneSize) { return ijkSubzoneSize.___2067() && ijkSubzoneSize.blockSize() <= ___2090::MAX_ITEM_OFFSET + 1; };
  18. static inline bool validFESubzoneSize(___2090::ItemOffset_t feSubzoneSize) { return feSubzoneSize > 0 && feSubzoneSize <= ___2090::MAX_ITEM_OFFSET + 1; };
  19. static inline bool validFileVersion(uint32_t fileVersion) { return fileVersion >= SZPLT_MIN_READ_VERSION; }
  20. private:
  21. ___372 m_isAscii;
  22. DataFileType_e m_dataFileType;
  23. ___1844 m_maxIJKSubzoneSize;
  24. ___2090::ItemOffset_t m_maxFESubzoneSize;
  25. uint32_t m_fileVersion;
  26. uint32_t m_codeRevision;
  27. public:
  28. ___1388() { invalidate(); }
  29. ___1388(___372 const ___2002, DataFileType_e ___844, ___1844 const &ijkSubzoneSize, ___2090::ItemOffset_t const feSubzoneSize)
  30. {
  31. invalidate();
  32. ___3494(___2002);
  33. setDataFileType(___844);
  34. setMaxIJKSubzoneSize(ijkSubzoneSize);
  35. setMaxFESubzoneSize(feSubzoneSize);
  36. setFileVersion(SZPLT_CUR_WRITE_VERSION);
  37. }
  38. inline void invalidate(void)
  39. {
  40. m_isAscii = ___372(-1);
  41. m_dataFileType = ___847;
  42. m_maxIJKSubzoneSize.invalidate();
  43. m_maxFESubzoneSize = ___2090::INVALID_ITEM_OFFSET;
  44. m_fileVersion = 0;
  45. m_codeRevision = 0;
  46. }
  47. #if 0
  48. inline bool operator ==(___1388 const& ___1308) const { return ___2002() == ___1308.___2002() && ___844() == ___1308.m_dataFileType() && ___1757() == ___1308.___1757() && ___1756() == ___1308.___1756() && getFileVersion() == ___1308.getFileVersion() && getRevision() == ___1308.getRevision(); } inline bool operator !=(___1388 const& ___1308) const { return !(*this == ___1308); }
  49. #endif
  50. inline void ___3494(___372 ___2002)
  51. {
  52. REQUIRE(validIsAscii(___2002));
  53. m_isAscii = ___2002;
  54. }
  55. inline void setDataFileType(DataFileType_e ___844)
  56. {
  57. REQUIRE(validDataFileType(___844));
  58. m_dataFileType = ___844;
  59. }
  60. inline void setMaxIJKSubzoneSize(___1844 const &maxIJKSubzoneSize)
  61. {
  62. REQUIRE(validIJKSubzoneSize(maxIJKSubzoneSize));
  63. m_maxIJKSubzoneSize = maxIJKSubzoneSize;
  64. }
  65. inline void setMaxFESubzoneSize(___2090::ItemOffset_t maxFESubzoneSize)
  66. {
  67. REQUIRE(validFESubzoneSize(maxFESubzoneSize));
  68. m_maxFESubzoneSize = maxFESubzoneSize;
  69. }
  70. inline void setFileVersion(uint32_t fileVersion) { m_fileVersion = fileVersion; }
  71. inline void setCodeRevision(uint32_t codeRevision) { m_codeRevision = codeRevision; }
  72. inline ___372 ___2002() const
  73. {
  74. ENSURE(VALID_BOOLEAN(m_isAscii));
  75. return m_isAscii;
  76. }
  77. inline DataFileType_e ___844() const
  78. {
  79. ENSURE(VALID_ENUM(m_dataFileType, DataFileType_e));
  80. return m_dataFileType;
  81. }
  82. inline ___1844 const &___1757() const
  83. {
  84. ENSURE(validIJKSubzoneSize(m_maxIJKSubzoneSize));
  85. return m_maxIJKSubzoneSize;
  86. }
  87. inline ___2090::ItemOffset_t ___1756() const
  88. {
  89. ENSURE(validFESubzoneSize(m_maxFESubzoneSize));
  90. return m_maxFESubzoneSize;
  91. }
  92. inline uint32_t getFileVersion() const
  93. {
  94. ENSURE(validFileVersion(m_fileVersion));
  95. return m_fileVersion;
  96. }
  97. inline uint32_t getCodeRevision() const { return m_codeRevision; }
  98. };
  99. }
  100. }