opennurbs_3dm_properties.h
Go to the documentation of this file.
00001 /* $NoKeywords: $ */
00002 /*
00003 //
00004 // Copyright (c) 1993-2012 Robert McNeel & Associates. All rights reserved.
00005 // OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert
00006 // McNeel & Associates.
00007 //
00008 // THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY.
00009 // ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF
00010 // MERCHANTABILITY ARE HEREBY DISCLAIMED.
00011 //                              
00012 // For complete openNURBS copyright information see <http://www.opennurbs.org>.
00013 //
00015 */
00016 
00017 #if !defined(OPENNURBS_3DM_PROPERTIES_INC_)
00018 #define OPENNURBS_3DM_PROPERTIES_INC_
00019 
00021 
00022 class ON_CLASS ON_3dmRevisionHistory
00023 {
00024 public:
00025   ON_3dmRevisionHistory();
00026   ~ON_3dmRevisionHistory();
00027   // C++ default operator= and copy constructor work fine.
00028 
00029   void Default();
00030   ON_BOOL32 IsValid() const;
00031   int NewRevision(); // returns updated revision count
00032 
00033   ON_BOOL32 Read( ON_BinaryArchive& );
00034   ON_BOOL32 Write( ON_BinaryArchive& ) const;
00035 
00036   void Dump( ON_TextLog& ) const;
00037 
00038   /*
00039   Returns:
00040     true 
00041       if m_create_time is >= January 1, 1970
00042   */
00043   bool CreateTimeIsSet() const;
00044 
00045   /*
00046   Returns:
00047     true 
00048       if m_last_edit_time is >= January 1, 1970
00049   */
00050   bool LastEditedTimeIsSet() const;
00051 
00052   ON_wString m_sCreatedBy;
00053   ON_wString m_sLastEditedBy;
00054   struct tm  m_create_time;     // UCT create time
00055   struct tm  m_last_edit_time;  // UCT las edited time
00056   int        m_revision_count;
00057 };
00058 
00060 
00061 class ON_CLASS ON_3dmNotes
00062 {
00063 public:
00064   ON_3dmNotes();
00065   ON_3dmNotes( const ON_3dmNotes& );
00066   ~ON_3dmNotes();
00067   ON_3dmNotes& operator=(const ON_3dmNotes&);
00068 
00069   void Default();
00070   ON_BOOL32 IsValid() const;
00071 
00072   ON_BOOL32 Read( ON_BinaryArchive& );
00073   ON_BOOL32 Write( ON_BinaryArchive& ) const;
00074 
00075   void Dump(ON_TextLog&) const;
00076 
00078   //
00079   // Interface - this information is serialized.  Applications
00080   // may want to derive a runtime class that has additional
00081   // window and font information.
00082   ON_wString m_notes; // UNICODE
00083   ON_BOOL32 m_bVisible;    // true if notes window is showing
00084   ON_BOOL32 m_bHTML;       // true if notes are in HTML
00085 
00086   // last window position
00087   int m_window_left;
00088   int m_window_top;
00089   int m_window_right;
00090   int m_window_bottom;
00091 };
00092 
00094 
00095 class ON_CLASS ON_3dmApplication
00096 {
00097   // application that created the 3dm file
00098 public:
00099   ON_3dmApplication();
00100   ON_3dmApplication( const ON_3dmApplication& );
00101   ~ON_3dmApplication();
00102   ON_3dmApplication& operator=(const ON_3dmApplication&);
00103 
00104   void Default();
00105   ON_BOOL32 IsValid() const;
00106 
00107   ON_BOOL32 Read( ON_BinaryArchive& );
00108   ON_BOOL32 Write( ON_BinaryArchive& ) const;
00109 
00110   void Dump( ON_TextLog& ) const;
00111 
00112   ON_wString m_application_name;    // short name like "Rhino 2.0"
00113   ON_wString m_application_URL;     // URL
00114   ON_wString m_application_details; // whatever you want
00115 };
00116 
00118 
00119 class ON_CLASS ON_3dmProperties
00120 {
00121 public:
00122   ON_3dmProperties();
00123   ~ON_3dmProperties();
00124   ON_3dmProperties(const ON_3dmProperties&);
00125   ON_3dmProperties& operator=(const ON_3dmProperties&);
00126 
00127   void Default();
00128 
00129   ON_BOOL32 Read(ON_BinaryArchive&);
00130   ON_BOOL32 Write(ON_BinaryArchive&) const;
00131 
00132   void Dump( ON_TextLog& ) const;
00133 
00134   ON_3dmRevisionHistory  m_RevisionHistory;
00135   ON_3dmNotes            m_Notes;
00136   ON_WindowsBitmap       m_PreviewImage;     // preview image of model
00137   ON_3dmApplication      m_Application;      // application that created 3DM file
00138 };
00139 
00141 
00142 #endif


pcl
Author(s): Open Perception
autogenerated on Wed Aug 26 2015 15:26:58