CFx SDK Documentation  2023 SP0
Tf.h
Go to the documentation of this file.
1 // Copyright (C) 2002-2017, Open Design Alliance (the "Alliance").
3 // All rights reserved.
4 //
5 // This software and its documentation and related materials are owned by
6 // the Alliance. The software may only be incorporated into application
7 // programs owned by members of the Alliance, subject to a signed
8 // Membership Agreement and Supplemental Software License Agreement with the
9 // Alliance. The structure and organization of this software are the valuable
10 // trade secrets of the Alliance and its suppliers. The software is also
11 // protected by copyright law and international treaty provisions. Application
12 // programs incorporating this software must include the following statement
13 // with their copyright notices:
14 //
15 // This application incorporates Teigha(R) software pursuant to a license
16 // agreement with Open Design Alliance.
17 // Teigha(R) Copyright (C) 2002-2017 by Open Design Alliance.
18 // All rights reserved.
19 //
20 // By use of this software, its documentation or related materials, you
21 // acknowledge and accept the above terms.
23 
24 
25 #ifndef _OD_TF_Included_
26 #define _OD_TF_Included_
27 
28 #include "DbHandle.h"
29 #include "DbObjectId.h"
30 #include "DbDatabase.h"
31 #include "Ge/GePoint2d.h"
32 #include "Ge/GePoint3d.h"
33 #include "Ge/GeScale3d.h"
34 
35 #include "TD_PackPush.h"
36 
37 #ifdef TF_DLL_EXPORTS
38 #define TFDLL_EXPORT OD_TOOLKIT_EXPORT
39 #define TFDLL_EXPORT_STATIC OD_STATIC_EXPORT
40 #else
41 #define TFDLL_EXPORT OD_TOOLKIT_IMPORT
42 #define TFDLL_EXPORT_STATIC OD_STATIC_IMPORT
43 #endif
44 
45 struct OdTfFiler
46 {
47  virtual OdRxObject* database() const = 0;
48 
49  virtual void seek(OdInt64 offset, OdDb::FilerSeekType seekType) = 0;
50 
54  virtual OdUInt64 tell() const = 0;
55 
59  virtual bool rdBool() = 0;
60 
65  virtual OdString rdString() = 0;
66 
73  virtual void rdBytes(
74  void* buffer,
75  OdUInt32 numBytes) = 0;
76 
80  virtual OdInt8 rdInt8() = 0;
81 
85  virtual OdUInt8 rdUInt8() = 0;
86 
90  virtual OdInt16 rdInt16() = 0;
91 
95  virtual OdInt32 rdInt32() = 0;
96 
100  virtual OdInt64 rdInt64() = 0;
101 
105  virtual double rdDouble() = 0;
106 
110  virtual OdDbHandle rdDbHandle() = 0;
111 
115  virtual OdDbStub* rdSoftOwnershipId() = 0;
116 
120  virtual OdDbStub* rdHardOwnershipId() = 0;
121 
125  virtual OdDbStub* rdHardPointerId() = 0;
126 
130  virtual OdDbStub* rdSoftPointerId() = 0;
131 
135  virtual OdGePoint2d rdPoint2d() = 0;
136 
140  virtual OdGePoint3d rdPoint3d() = 0;
141 
145  virtual OdGeVector2d rdVector2d() = 0;
146 
150  virtual OdGeVector3d rdVector3d() = 0;
151 
155  virtual OdGeScale3d rdScale3d() = 0;
156 
162  virtual void wrBool(
163  bool value) = 0;
164 
170  virtual void wrString(
171  const OdString &value) = 0;
172 
179  virtual void wrBytes(
180  const void* buffer,
181  OdUInt32 numBytes) = 0;
182 
188  virtual void wrInt8(
189  OdInt8 value) = 0;
190 
196  virtual void wrUInt8(
197  OdUInt8 value) = 0;
198 
204  virtual void wrInt16(
205  OdInt16 value) = 0;
206 
212  virtual void wrInt32(
213  OdInt32 value) = 0;
214 
220  virtual void wrInt64(
221  OdInt64 value) = 0;
222 
223 
229  virtual void wrDouble(double value) = 0;
230 
236  virtual void wrDbHandle(
237  const OdDbHandle& value) = 0;
238 
244  virtual void wrSoftOwnershipId(
245  OdDbStub* value) = 0;
246 
252  virtual void wrHardOwnershipId(
253  OdDbStub* value) = 0;
254 
260  virtual void wrSoftPointerId(
261  OdDbStub* value) = 0;
262 
268  virtual void wrHardPointerId(
269  OdDbStub* value) = 0;
270 
276  virtual void wrPoint2d(
277  const OdGePoint2d& value) = 0;
278 
284  virtual void wrPoint3d(
285  const OdGePoint3d& value) = 0;
286 
292  virtual void wrVector2d(
293  const OdGeVector2d& value) = 0;
294 
300  virtual void wrVector3d(
301  const OdGeVector3d& value) = 0;
302 
308  virtual void wrScale3d(
309  const OdGeScale3d& value) = 0;
310 
311  virtual void wrSubobject(int id, const char* name) = 0;
312  virtual const char* rdSubobject(int& id) = 0;
313  virtual void wrDateTime(OdTimeStamp) = 0;
314  virtual void rdDateTime(OdTimeStamp&) = 0;
315 };
316 
317 
319 {
321  virtual int schemaVersion(OdRxObject*) = 0;
322  virtual OdString schema(OdRxObject*) = 0;
323  virtual bool in(OdRxObject*, OdTfFiler*) = 0;
324  virtual void out(OdRxObject*, OdTfFiler*) = 0;
325 };
326 
328 
329 namespace OdTf
330 {
331  enum TagsEnum {
332  Element = 1,
334  Array = 4,
335  version = 8,
336  EndClass = 16,
337  Mark = 32,
338 
339  EndTagMask = 64
340  };
341 
343  {
346  deletedInVersion = 2
347  };
348 
351  isBreak = 2,
357  isSum = 128
358  };
359 
362  isOwner = 2,
363  dwgVer = 4
364  };
365 
367  breakValue = 1
368  };
369 
371  kTrue = 1,
372  kFalse = 2,
373  kNot = 4,
374  kAnd = 8,
375  kLessThan = 16,
376  kGreaterThan = 32
377  };
378 
381  reduceIn = 2,
382  limitLen = 4,
384  mul = 16,
385  value = 32,
386  cacheValue = 64
387  };
388 
390  {
416  Empty
417  };
418 }
419 
420 
421 #include "TD_PackPop.h"
422 
423 #endif // _OD_TF_Included_
unsigned int OdUInt32
short OdInt16
signed char OdInt8
int OdInt32
unsigned char OdUInt8
OdSmartPtr< OdTfObjectPE > OdTfObjectPEPtr
Definition: Tf.h:327
#define TFDLL_EXPORT
Definition: Tf.h:41
Definition: Int64.h:43
GLuint buffer
Definition: gles2_ext.h:178
GLuint const GLchar * name
Definition: gles2_ext.h:265
GLintptr offset
Definition: gles2_ext.h:183
GLsizei const GLfloat * value
Definition: gles2_ext.h:302
FilerSeekType
Definition: OdStreamBuf.h:49
Definition: Tf.h:330
TagsEnum
Definition: Tf.h:331
@ EndTagMask
Definition: Tf.h:339
@ EndClass
Definition: Tf.h:336
@ version
Definition: Tf.h:335
@ Condition
Definition: Tf.h:333
@ Element
Definition: Tf.h:332
@ Mark
Definition: Tf.h:337
@ Array
Definition: Tf.h:334
ConditionAttributesEnum
Definition: Tf.h:360
@ isMarkCondition
Definition: Tf.h:361
@ isOwner
Definition: Tf.h:362
@ dwgVer
Definition: Tf.h:363
HexBinaryAttributesEnum
Definition: Tf.h:379
@ cacheValue
Definition: Tf.h:386
@ countBytes
Definition: Tf.h:383
@ reduceIn
Definition: Tf.h:381
@ increaseIn
Definition: Tf.h:380
@ mul
Definition: Tf.h:384
@ limitLen
Definition: Tf.h:382
TypesEnum
Definition: Tf.h:390
@ Int
Definition: Tf.h:395
@ Handle
Definition: Tf.h:403
@ Vector3d
Definition: Tf.h:411
@ String
Definition: Tf.h:402
@ HardPointerId
Definition: Tf.h:407
@ Point3d
Definition: Tf.h:409
@ Subclass
Definition: Tf.h:391
@ SoftOwnershipId
Definition: Tf.h:404
@ UnsignedByte
Definition: Tf.h:396
@ SoftPointerId
Definition: Tf.h:406
@ Vector2d
Definition: Tf.h:410
@ HardOwnershipId
Definition: Tf.h:405
@ Empty
Definition: Tf.h:416
@ DataEnd
Definition: Tf.h:414
@ Long
Definition: Tf.h:399
@ Table
Definition: Tf.h:415
@ Double
Definition: Tf.h:400
@ DateTime
Definition: Tf.h:413
@ Short
Definition: Tf.h:394
@ UnsignedInt
Definition: Tf.h:398
@ HexBinary
Definition: Tf.h:401
@ Byte
Definition: Tf.h:393
@ Bool
Definition: Tf.h:392
@ Point2d
Definition: Tf.h:408
@ Scale3d
Definition: Tf.h:412
@ UnsignedShort
Definition: Tf.h:397
ConditionOperatorsEnum
Definition: Tf.h:370
@ kTrue
Definition: Tf.h:371
@ kLessThan
Definition: Tf.h:375
@ kAnd
Definition: Tf.h:374
@ kNot
Definition: Tf.h:373
@ kGreaterThan
Definition: Tf.h:376
@ kFalse
Definition: Tf.h:372
ArrayAttributesEnum
Definition: Tf.h:366
@ breakValue
Definition: Tf.h:367
ElementAttributesEnum
Definition: Tf.h:349
@ isContextData
Definition: Tf.h:353
@ isSum
Definition: Tf.h:357
@ isTableCache
Definition: Tf.h:355
@ isTableQueue
Definition: Tf.h:354
@ isCacheValue
Definition: Tf.h:350
@ isTableName
Definition: Tf.h:352
@ TableQueue
Definition: Tf.h:356
@ isBreak
Definition: Tf.h:351
ClassVersionEnum
Definition: Tf.h:343
@ deletedInVersion
Definition: Tf.h:346
@ addInVersion
Definition: Tf.h:345
@ originalVersion
Definition: Tf.h:344
Definition: Tf.h:46
virtual void wrBool(bool value)=0
virtual void rdBytes(void *buffer, OdUInt32 numBytes)=0
virtual void wrHardOwnershipId(OdDbStub *value)=0
virtual void seek(OdInt64 offset, OdDb::FilerSeekType seekType)=0
virtual void wrSubobject(int id, const char *name)=0
virtual OdInt8 rdInt8()=0
virtual void wrVector3d(const OdGeVector3d &value)=0
virtual bool rdBool()=0
virtual void wrDbHandle(const OdDbHandle &value)=0
virtual void wrSoftOwnershipId(OdDbStub *value)=0
virtual OdGeVector3d rdVector3d()=0
virtual void wrBytes(const void *buffer, OdUInt32 numBytes)=0
virtual OdDbHandle rdDbHandle()=0
virtual void wrScale3d(const OdGeScale3d &value)=0
virtual void wrInt64(OdInt64 value)=0
virtual void wrInt8(OdInt8 value)=0
virtual OdDbStub * rdSoftPointerId()=0
virtual void wrDateTime(OdTimeStamp)=0
virtual OdGePoint3d rdPoint3d()=0
virtual OdGePoint2d rdPoint2d()=0
virtual OdDbStub * rdHardOwnershipId()=0
virtual OdDbStub * rdSoftOwnershipId()=0
virtual void rdDateTime(OdTimeStamp &)=0
virtual OdDbStub * rdHardPointerId()=0
virtual void wrUInt8(OdUInt8 value)=0
virtual OdInt32 rdInt32()=0
virtual const char * rdSubobject(int &id)=0
virtual void wrVector2d(const OdGeVector2d &value)=0
virtual OdInt64 rdInt64()=0
virtual void wrPoint2d(const OdGePoint2d &value)=0
virtual OdGeVector2d rdVector2d()=0
virtual void wrInt32(OdInt32 value)=0
virtual void wrHardPointerId(OdDbStub *value)=0
virtual void wrString(const OdString &value)=0
virtual OdInt16 rdInt16()=0
virtual OdUInt64 tell() const =0
virtual double rdDouble()=0
virtual OdUInt8 rdUInt8()=0
virtual OdString rdString()=0
virtual void wrInt16(OdInt16 value)=0
virtual OdRxObject * database() const =0
virtual void wrDouble(double value)=0
virtual void wrSoftPointerId(OdDbStub *value)=0
virtual void wrPoint3d(const OdGePoint3d &value)=0
virtual OdGeScale3d rdScale3d()=0
virtual int schemaVersion(OdRxObject *)=0
virtual bool in(OdRxObject *, OdTfFiler *)=0
virtual void out(OdRxObject *, OdTfFiler *)=0
virtual OdString schema(OdRxObject *)=0
ODRX_DECLARE_MEMBERS(OdTfObjectPE)