File indexing completed on 2025-01-18 10:05:17
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017 #ifndef _Storage_HeaderData_HeaderFile
0018 #define _Storage_HeaderData_HeaderFile
0019
0020 #include <Standard.hxx>
0021 #include <Standard_Type.hxx>
0022
0023 #include <Standard_Integer.hxx>
0024 #include <TColStd_SequenceOfAsciiString.hxx>
0025 #include <TColStd_SequenceOfExtendedString.hxx>
0026 #include <Storage_Error.hxx>
0027 #include <Standard_Transient.hxx>
0028 class Storage_BaseDriver;
0029
0030
0031 class Storage_HeaderData;
0032 DEFINE_STANDARD_HANDLE(Storage_HeaderData, Standard_Transient)
0033
0034
0035 class Storage_HeaderData : public Standard_Transient
0036 {
0037
0038 public:
0039
0040
0041 Standard_EXPORT Storage_HeaderData();
0042
0043 Standard_EXPORT Standard_Boolean Read (const Handle(Storage_BaseDriver)& theDriver);
0044
0045
0046 Standard_EXPORT TCollection_AsciiString CreationDate() const;
0047
0048
0049 Standard_EXPORT TCollection_AsciiString StorageVersion() const;
0050
0051
0052 Standard_EXPORT TCollection_AsciiString SchemaVersion() const;
0053
0054
0055 Standard_EXPORT TCollection_AsciiString SchemaName() const;
0056
0057
0058 Standard_EXPORT void SetApplicationVersion (const TCollection_AsciiString& aVersion);
0059
0060
0061 Standard_EXPORT TCollection_AsciiString ApplicationVersion() const;
0062
0063
0064 Standard_EXPORT void SetApplicationName (const TCollection_ExtendedString& aName);
0065
0066
0067 Standard_EXPORT TCollection_ExtendedString ApplicationName() const;
0068
0069
0070 Standard_EXPORT void SetDataType (const TCollection_ExtendedString& aType);
0071
0072
0073 Standard_EXPORT TCollection_ExtendedString DataType() const;
0074
0075
0076 Standard_EXPORT void AddToUserInfo (const TCollection_AsciiString& theUserInfo);
0077
0078
0079 Standard_EXPORT const TColStd_SequenceOfAsciiString& UserInfo() const;
0080
0081
0082 Standard_EXPORT void AddToComments (const TCollection_ExtendedString& aComment);
0083
0084
0085 Standard_EXPORT const TColStd_SequenceOfExtendedString& Comments() const;
0086
0087
0088
0089
0090 Standard_EXPORT Standard_Integer NumberOfObjects() const;
0091
0092 Standard_EXPORT Storage_Error ErrorStatus() const;
0093
0094 Standard_EXPORT TCollection_AsciiString ErrorStatusExtension() const;
0095
0096 Standard_EXPORT void ClearErrorStatus();
0097
0098
0099 friend class Storage_Schema;
0100
0101
0102 DEFINE_STANDARD_RTTIEXT(Storage_HeaderData,Standard_Transient)
0103
0104 public:
0105
0106 Standard_EXPORT void SetNumberOfObjects (const Standard_Integer anObjectNumber);
0107
0108 Standard_EXPORT void SetStorageVersion (const TCollection_AsciiString& aVersion);
0109
0110 void SetStorageVersion (const Standard_Integer theVersion)
0111 {
0112 SetStorageVersion (TCollection_AsciiString (theVersion));
0113 }
0114
0115 Standard_EXPORT void SetCreationDate (const TCollection_AsciiString& aDate);
0116
0117 Standard_EXPORT void SetSchemaVersion (const TCollection_AsciiString& aVersion);
0118
0119 Standard_EXPORT void SetSchemaName (const TCollection_AsciiString& aName);
0120
0121 private:
0122
0123 Standard_EXPORT void SetErrorStatus (const Storage_Error anError);
0124
0125 Standard_EXPORT void SetErrorStatusExtension (const TCollection_AsciiString& anErrorExt);
0126
0127 Standard_Integer myNBObj;
0128 TCollection_AsciiString myStorageVersion;
0129 TCollection_AsciiString mySchemaVersion;
0130 TCollection_AsciiString mySchemaName;
0131 TCollection_AsciiString myApplicationVersion;
0132 TCollection_ExtendedString myApplicationName;
0133 TCollection_ExtendedString myDataType;
0134 TCollection_AsciiString myDate;
0135 TColStd_SequenceOfAsciiString myUserInfo;
0136 TColStd_SequenceOfExtendedString myComments;
0137 Storage_Error myErrorStatus;
0138 TCollection_AsciiString myErrorStatusExt;
0139
0140
0141 };
0142
0143
0144
0145
0146
0147
0148
0149 #endif