| TerraLib 4.1

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files
- Examples

- File List
- File Members

E:/Projetos_Primeiro_Semestre_2012/TerraView/terralib/src/dxflib/dl_creationinterface.h
Go to the documentation of this file.

    00001 /****************************************************************************
    00002 ** $Id: dl_creationinterface.h 8171 2009-12-11 12:31:36Z fredbed $
    00003 **
    00004 ** Copyright (C) 2001-2003 RibbonSoft. All rights reserved.
    00005 **
    00006 ** This file is part of the dxflib project.
    00007 **
    00008 ** This file may be distributed and/or modified under the terms of the
    00009 ** GNU General Public License version 2 as published by the Free Software
    00010 ** Foundation and appearing in the file LICENSE.GPL included in the
    00011 ** packaging of this file.
    00012 **
    00013 ** Licensees holding valid dxflib Professional Edition licenses may use
    00014 ** this file in accordance with the dxflib Commercial License
    00015 ** Agreement provided with the Software.
    00016 **
    00017 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
    00018 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
    00019 **
    00020 ** See http://www.ribbonsoft.com for further details.
    00021 **
    00022 ** Contact info@ribbonsoft.com if any conditions of this licensing are
    00023 ** not clear to you.
    00024 **
    00025 **********************************************************************/
    00026
    00027 #ifndef DL_CREATIONINTERFACE_H
    00028 #define DL_CREATIONINTERFACE_H
    00029
    00030 #include <string.h>
    00031
    00032 #include "dl_attributes.h"
    00033 #include "dl_codes.h"
    00034 #include "dl_entities.h"
    00035 #include "dl_extrusion.h"
    00036
    00047 class DL_CreationInterface {
    00048 public:
    00049     DL_CreationInterface() {
    00050         extrusion = new DL_Extrusion;
    00051     }
    00052     virtual ~DL_CreationInterface() {
    00053         delete extrusion;
    00054     }
    00055
    00059     virtual void addLayer(const DL_LayerData& data) = 0;
    00060
    00067     virtual void addBlock(const DL_BlockData& data) = 0;
    00068
    00070     virtual void endBlock() = 0;
    00071
    00073     virtual void addPoint(const DL_PointData& data) = 0;
    00074
    00076     virtual void addLine(const DL_LineData& data) = 0;
    00077
    00079     virtual void addArc(const DL_ArcData& data) = 0;
    00080
    00082     virtual void addCircle(const DL_CircleData& data) = 0;
    00083
    00085     virtual void addEllipse(const DL_EllipseData& data) = 0;
    00086
    00088     virtual void addPolyline(const DL_PolylineData& data) = 0;
    00089
    00091     virtual void addVertex(const DL_VertexData& data) = 0;
    00092
    00094     virtual void addSpline(const DL_SplineData& data) = 0;
    00095
    00097     virtual void addControlPoint(const DL_ControlPointData& data) = 0;
    00098
    00100     virtual void addKnot(const DL_KnotData& data) = 0;
    00101
    00103     virtual void addInsert(const DL_InsertData& data) = 0;
    00104
    00106     virtual void addTrace(const DL_TraceData& data) = 0;
    00107
    00109     virtual void add3dFace(const DL_3dFaceData& data) = 0;
    00110
    00112     virtual void addSolid(const DL_SolidData& data) = 0;
    00113
    00114
    00116     virtual void addMText(const DL_MTextData& data) = 0;
    00117
    00123     virtual void addMTextChunk(const char* text) = 0;
    00124
    00126     virtual void addText(const DL_TextData& data) = 0;
    00127
    00131     virtual void addDimAlign(const DL_DimensionData& data,
    00132                              const DL_DimAlignedData& edata) = 0;
    00136     virtual void addDimLinear(const DL_DimensionData& data,
    00137                               const DL_DimLinearData& edata) = 0;
    00138
    00142     virtual void addDimRadial(const DL_DimensionData& data,
    00143                               const DL_DimRadialData& edata) = 0;
    00144
    00148     virtual void addDimDiametric(const DL_DimensionData& data,
    00149                               const DL_DimDiametricData& edata) = 0;
    00150
    00154     virtual void addDimAngular(const DL_DimensionData& data,
    00155                               const DL_DimAngularData& edata) = 0;
    00156
    00160     virtual void addDimAngular3P(const DL_DimensionData& data,
    00161                               const DL_DimAngular3PData& edata) = 0;
    00162
    00166     virtual void addDimOrdinate(const DL_DimensionData& data,
    00167                              const DL_DimOrdinateData& edata) = 0;
    00168
    00172     virtual void addLeader(const DL_LeaderData& data) = 0;
    00173
    00177     virtual void addLeaderVertex(const DL_LeaderVertexData& data) = 0;
    00178
    00182     virtual void addHatch(const DL_HatchData& data) = 0;
    00183
    00187     virtual void addImage(const DL_ImageData& data) = 0;
    00188
    00192            virtual void linkImage(const DL_ImageDefData& data) = 0;
    00193
    00197     virtual void addHatchLoop(const DL_HatchLoopData& data) = 0;
    00198
    00202     virtual void addHatchEdge(const DL_HatchEdgeData& data) = 0;
    00203
    00207     virtual void endEntity() = 0;
    00208
    00212     virtual void addComment(const char* comment) = 0;
    00213
    00217     virtual void setVariableVector(const char* key,
    00218                           double v1, double v2, double v3, int code) = 0;
    00219
    00223     virtual void setVariableString(const char* key, const char* value, int code) = 0;
    00224
    00228     virtual void setVariableInt(const char* key, int value, int code) = 0;
    00229
    00233     virtual void setVariableDouble(const char* key, double value, int code) = 0;
    00234
    00238      virtual void endSequence() = 0;
    00239
    00241     void setAttributes(const DL_Attributes& attrib) {
    00242         attributes = attrib;
    00243     }
    00244
    00246     DL_Attributes getAttributes() {
    00247         return attributes;
    00248     }
    00249
    00251     void setExtrusion(double dx, double dy, double dz, double elevation) {
    00252         extrusion->setDirection(dx, dy, dz);
    00253                       extrusion->setElevation(elevation);
    00254     }
    00255
    00257     DL_Extrusion* getExtrusion() {
    00258         return extrusion;
    00259     }
    00260
    00261 protected:
    00262     DL_Attributes attributes;
    00263     DL_Extrusion *extrusion;
    00264 };
    00265
    00266 #endif

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines