Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:05:00

0001 // Copyright (c) 2015 OPEN CASCADE SAS
0002 //
0003 // This file is part of Open CASCADE Technology software library.
0004 //
0005 // This library is free software; you can redistribute it and/or modify it under
0006 // the terms of the GNU Lesser General Public License version 2.1 as published
0007 // by the Free Software Foundation, with special exception defined in the file
0008 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0009 // distribution for complete text of the license and disclaimer of any warranty.
0010 //
0011 // Alternatively, this file may be used under the terms of Open CASCADE
0012 // commercial license or contractual agreement.
0013 
0014 
0015 #ifndef _StdPersistent_DataXtd_PatternStd_HeaderFile
0016 #define _StdPersistent_DataXtd_PatternStd_HeaderFile
0017 
0018 #include <StdObjMgt_Attribute.hxx>
0019 
0020 #include <TDataXtd_PatternStd.hxx>
0021 
0022 
0023 class StdPersistent_DataXtd_PatternStd
0024   : public StdObjMgt_Attribute<TDataXtd_PatternStd>
0025 {
0026 public:
0027   //! Read persistent data from a file.
0028   inline void Read (StdObjMgt_ReadData& theReadData)
0029   {
0030     theReadData >> mySignature >> myAxis1Reversed >> myAxis2Reversed >>
0031       myAxis1 >> myAxis2 >> myValue1 >> myValue2 >> myNb1 >> myNb2 >> myMirror;
0032   }
0033   //! Write persistent data to a file.
0034   inline void Write(StdObjMgt_WriteData& theWriteData)
0035   {
0036     theWriteData << mySignature << myAxis1Reversed << myAxis2Reversed <<
0037       myAxis1 << myAxis2 << myValue1 << myValue2 << myNb1 << myNb2 << myMirror;
0038   }
0039   //! Gets persistent child objects
0040   inline void PChildren(StdObjMgt_Persistent::SequenceOfPersistent& theChildren) const
0041   {
0042     theChildren.Append(myAxis1);
0043     theChildren.Append(myAxis2);
0044     theChildren.Append(myValue1);
0045     theChildren.Append(myValue2);
0046     theChildren.Append(myNb1);
0047     theChildren.Append(myNb2);
0048     theChildren.Append(myMirror);
0049   }
0050   //! Returns persistent type name
0051   inline Standard_CString PName() const { return "PDataXtd_PatternStd"; }
0052 
0053   //! Import transient attribute from the persistent data.
0054   void Import (const Handle(TDataXtd_PatternStd)& theAttribute) const;
0055 
0056 private:
0057   Standard_Integer             mySignature;
0058   Standard_Boolean             myAxis1Reversed;
0059   Standard_Boolean             myAxis2Reversed;
0060   Handle(StdObjMgt_Persistent) myAxis1;
0061   Handle(StdObjMgt_Persistent) myAxis2;
0062   Handle(StdObjMgt_Persistent) myValue1;
0063   Handle(StdObjMgt_Persistent) myValue2;
0064   Handle(StdObjMgt_Persistent) myNb1;
0065   Handle(StdObjMgt_Persistent) myNb2;
0066   Handle(StdObjMgt_Persistent) myMirror;
0067 };
0068 
0069 #endif