Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | Related Pages | Examples

blockref_defs.h

00001 //  Copyright (c) 1996-2001 by Autodesk, Inc.
00002 //
00003 //  By using this code, you are agreeing to the terms and conditions of
00004 //  the License Agreement included in the documentation for this code.
00005 //
00006 //  AUTODESK MAKES NO WARRANTIES, EXPRESS OR IMPLIED, AS TO THE CORRECTNESS
00007 //  OF THIS CODE OR ANY DERIVATIVE WORKS WHICH INCORPORATE IT. AUTODESK
00008 //  PROVIDES THE CODE ON AN "AS-IS" BASIS AND EXPLICITLY DISCLAIMS ANY
00009 //  LIABILITY, INCLUDING CONSEQUENTIAL AND INCIDENTAL DAMAGES FOR ERRORS,
00010 //  OMISSIONS, AND OTHER PROBLEMS IN THE CODE.
00011 //
00012 //  Use, duplication, or disclosure by the U.S. Government is subject to
00013 //  restrictions set forth in FAR 52.227-19 (Commercial Computer Software
00014 //  Restricted Rights) and DFAR 252.227-7013(c)(1)(ii) (Rights in Technical
00015 //  Data and Computer Software), as applicable.
00016 //
00017 
00018 #if !defined BLOCKREF_DEFS_HEADER
00019 #define BLOCKREF_DEFS_HEADER
00020 
00021 #include "whiptk/whipcore.h"
00022 #include "whiptk/object.h"
00023 
00024 class WT_File;
00025 
00027 
00029 class WHIPTK_API WT_Block_Meaning : public WT_Object
00030 {
00031 public:
00032 
00033     enum WT_Block_Description
00034     {
00035         None      = 0x00000001,
00036         Seal      = 0x00000002,
00037         Stamp     = 0x00000004,
00038         Label     = 0x00000008,
00039         Redline   = 0x00000010,
00040         Reserved1 = 0x00000020,
00041         Reserved2 = 0x00000040
00042     };
00043 
00044 private:
00045     WT_Block_Description   m_description;
00046     enum {
00047         Starting,
00048         Getting_Description,
00049         Getting_Close
00050     }   m_stage;
00051 
00052 public:
00053 
00054     // Constructors, Destructors
00055 
00056     WT_Block_Meaning()
00057       : m_description(None)
00058       , m_stage(Starting)
00059     { }
00060 
00061     WT_Block_Meaning(WT_Block_Description description)
00062       : m_description(description)
00063       , m_stage(Starting)
00064     { }
00065 
00066     ~WT_Block_Meaning()
00067     { }
00068 
00069     WT_ID            object_id() const;
00070     WT_Type          object_type() const;
00071     WT_Result        serialize (WT_File & file) const;
00072     WT_Result        materialize(WT_Opcode const & opcode,
00073                                                 WT_File & file);
00074     WT_Result        skip_operand(WT_Opcode const & opcode,
00075                                                 WT_File & file);
00076     WT_Result        process(WT_File & file);
00077 
00078     static WT_Result default_process(WT_Block_Meaning & item,
00079                                                 WT_File & file);
00080 
00081     // Get/Set methods
00082     void set_block_description(
00083         WT_Block_Meaning::WT_Block_Description description);
00084 
00085         WT_Block_Meaning::WT_Block_Description  get_block_description() const;
00086 
00087     WT_Boolean    operator!= (WT_Block_Meaning const &
00088                                                     meaning) const;
00089     WT_Boolean    operator== (WT_Block_Meaning const &
00090                                                     meaning) const;
00091 };
00092 
00094 
00097 class WHIPTK_API WT_Encryption : public WT_Object
00098 {
00099 public:
00100 
00101     enum WT_Encryption_Description
00102     {
00103         None      = 0x00000001,
00104         Reserved1 = 0x00000002,
00105         Reserved2 = 0x00000004,
00106         Reserved3 = 0x00000008
00107     };
00108 
00109 private:
00110     WT_Encryption_Description   m_description;
00111 
00112     enum {
00113         Starting,
00114         Getting_Description,
00115         Getting_Close
00116     }   m_stage;
00117 
00118 public:
00119 
00120     // Constructors, Destructors
00121 
00122     WT_Encryption()
00123       : m_description(None)
00124       , m_stage(Starting)
00125     { }
00126 
00127     WT_Encryption(WT_Encryption_Description description)
00128       : m_description(description)
00129       , m_stage(Starting)
00130     { }
00131 
00132     ~WT_Encryption()
00133     { }
00134 
00135     WT_ID            object_id() const;
00136     WT_Type          object_type() const;
00137     WT_Result        serialize (WT_File & file) const;
00138     WT_Result        materialize(WT_Opcode const & opcode,
00139                                                         WT_File & file);
00140     WT_Result        skip_operand(WT_Opcode const & opcode,
00141                                                         WT_File & file);
00142     WT_Result        process(WT_File & file);
00143 
00144     static WT_Result default_process(WT_Encryption & item,
00145                                                         WT_File & file);
00146 
00147     // Get/Set methods
00148     void set_encryption_description(
00149         WT_Encryption::WT_Encryption_Description description);
00150     WT_Encryption::WT_Encryption_Description
00151         get_encryption_description() const;
00152 
00153     WT_Boolean    operator!= (WT_Encryption const
00154                                                 & encryption) const;
00155     WT_Boolean    operator== (WT_Encryption const
00156                                                 & encryption) const;
00157 };
00158 
00160 
00162 class WHIPTK_API WT_Orientation : public WT_Object
00163 {
00164 public:
00165 
00166     enum WT_Orientation_Description
00167     {
00168         Always_In_Sync       = 0x00000001,
00169         Always_Different     = 0x00000002,
00170         Decoupled            = 0x00000004
00171     };
00172 
00173 private:
00174     WT_Orientation_Description   m_description;
00175 
00176     enum {
00177         Starting,
00178         Getting_Description,
00179         Getting_Close
00180     }   m_stage;
00181 
00182 public:
00183 
00184     // Constructors, Destructors
00185 
00186     WT_Orientation()
00187       : m_description(Always_In_Sync)
00188       , m_stage(Starting)
00189     { }
00190 
00191     WT_Orientation(WT_Orientation_Description description)
00192       : m_description(description)
00193       , m_stage(Starting)
00194     { }
00195 
00196     ~WT_Orientation()
00197     { }
00198 
00199     WT_ID            object_id() const;
00200     WT_Type          object_type() const;
00201     WT_Result        serialize (WT_File & file) const;
00202     WT_Result        materialize(WT_Opcode const & opcode,
00203                                                         WT_File & file);
00204     WT_Result        skip_operand(WT_Opcode const & opcode,
00205                                                         WT_File & file);
00206     WT_Result        process(WT_File & file);
00207 
00208     static WT_Result default_process(WT_Orientation & item,
00209                                                         WT_File & file);
00210 
00211     // Get/Set methods
00212     void set_orientation_description(
00213         WT_Orientation::WT_Orientation_Description description);
00214     WT_Orientation::WT_Orientation_Description
00215         get_orientation_description() const;
00216 
00217     WT_Boolean    operator!= (WT_Orientation const
00218                                             & orientation) const;
00219     WT_Boolean    operator== (WT_Orientation const
00220                                             & orientation) const;
00221 };
00222 
00224 
00226 class WHIPTK_API WT_Alignment : public WT_Object
00227 {
00228 public:
00229 
00230     enum WT_Alignment_Description
00231     {
00232         Align_Center        = 0x00000001,
00233         Align_Title_Block   = 0x00000002,
00234         Align_Top           = 0x00000004,
00235         Align_Bottom        = 0x00000008,
00236         Align_Left          = 0x00000010,
00237         Align_Right         = 0x00000020,
00238         Align_Top_Left      = 0x00000040,
00239         Align_Top_Right     = 0x00000080,
00240         Align_Bottom_Left   = 0x00000100,
00241         Align_Bottom_Right  = 0x00000200,
00242         Align_None          = 0x00000400
00243     };
00244 
00245 private:
00246     WT_Alignment_Description   m_description;
00247 
00248     enum {
00249         Starting,
00250         Getting_Description,
00251         Getting_Close
00252     }   m_stage;
00253 
00254 public:
00255 
00256     // Constructors, Destructors
00257 
00258     WT_Alignment()
00259       : m_description(Align_None)
00260       , m_stage(Starting)
00261     { }
00262 
00263     WT_Alignment(WT_Alignment_Description description)
00264       : m_description(description)
00265       , m_stage(Starting)
00266     { }
00267 
00268     ~WT_Alignment()
00269     { }
00270 
00271     WT_ID            object_id() const;
00272     WT_Type          object_type() const;
00273     WT_Result        serialize (WT_File & file) const;
00274     WT_Result        materialize(WT_Opcode const & opcode,
00275                                                         WT_File & file);
00276     WT_Result        skip_operand(WT_Opcode const & opcode,
00277                                                         WT_File & file);
00278     WT_Result        process(WT_File & file);
00279 
00280     static WT_Result default_process(WT_Alignment & item,
00281                                                         WT_File & file);
00282 
00283     // Get/Set methods
00284     void set_alignment_description(
00285         WT_Alignment::WT_Alignment_Description description);
00286     WT_Alignment::WT_Alignment_Description
00287         get_alignment_description() const;
00288 
00289     WT_Boolean    operator!= (WT_Alignment const
00290                                             & alignment) const;
00291     WT_Boolean    operator== (WT_Alignment const
00292                                             & alignment) const;
00293 };
00294 
00295 
00297 
00299 class WHIPTK_API WT_Password : public WT_Object
00300 {
00301     protected:
00302         WT_Byte m_string[33];
00303     public:
00304         WT_Password()
00305         {
00306             memset(&m_string[0], '\0', 33);
00307         }
00308         WT_Password(char * string);
00309         WT_Password(WT_Unsigned_Integer16 * string);
00310         WT_Password(WT_Password const & info);
00311         WT_Object::WT_ID    object_id() const;
00312         WT_Object::WT_Type object_type() const;
00313         WT_Result process(WT_File & file);
00314         WT_Result skip_operand(WT_Opcode const & opcode, WT_File & file);
00315         static WT_Result default_process(WT_Password & item, WT_File & file);
00316         void set(char const * string);
00317         void set(WT_Unsigned_Integer16 const * string);
00318         void set(WT_String const & string);
00319         WT_Byte * const     string(void) const;
00320         WT_Unsigned_Integer16 const  get_string_length(void);
00321         WT_Result serialize(WT_File & file) const;
00322         WT_Result materialize(WT_Opcode const & opcode, WT_File & file);
00323         WT_Password    operator= (WT_Password const & Password) ;
00324         WT_Boolean    operator!= (WT_Password const & Password) const;
00325         WT_Boolean    operator== (WT_Password const & Password) const;
00326 };                                                                                                  //
00327 
00329 
00331 class WHIPTK_API WT_Guid : public WT_Object, public WT_Item
00332 {
00333 private:
00334     WD_GUID  m_guid;
00335 enum {
00336     Starting,
00337     Getting_Data1,
00338     Getting_Data2,
00339     Getting_Data3,
00340     Getting_Data4,
00341     Getting_Close
00342 }   m_stage;
00343 
00344     void _deleteObject(void *object)
00345     {
00346         delete (WT_Guid*)object;
00347     }
00348 
00349 
00350 public:
00351     WT_Guid()
00352         : m_guid ()
00353         , m_stage(Starting)
00354     {
00355         memset((void *) &m_guid, 0, sizeof(WD_GUID));
00356     }
00357 
00358     WT_Guid(const WD_GUID guid);
00359     WT_Guid(WT_Guid const & info);
00360     WT_Object::WT_ID    object_id() const;
00361     WT_Object::WT_Type object_type() const;
00362     WT_Result process(WT_File & file);
00363     WT_Result skip_operand(WT_Opcode const & opcode, WT_File & file);
00364     static WT_Result default_process(WT_Guid & item, WT_File & file);
00365     void set(WD_GUID guid);
00366     void set(WT_Guid guid);
00367     WD_GUID get_guid();
00368     WT_Result serialize(WT_File & file) const;
00369     WT_Result materialize(WT_Opcode const & opcode, WT_File & file);
00370     WT_Boolean operator!=(WT_Guid const & in) const  ;
00371     WT_Boolean operator==(WT_Guid const & in) const  ;
00372     WT_Guid operator=(WT_Guid const & in) const  ;
00373 
00374 };
00375 
00376 #endif // BLOCKREF_DEFS_HEADER

Generated on Tue May 17 12:07:43 2005 for Autodesk DWF Whip 2D Toolkit by  doxygen 1.4.1