root / branches / v2_0_0_prep / libraries / libDwg / src / com / iver / cit / jdwglib / dwg / objects / DwgMesh.java @ 23335
History | View | Annotate | Download (3.89 KB)
1 | 10103 | azabala | /*
|
---|---|---|---|
2 | * Created on 03-feb-2007
|
||
3 | *
|
||
4 | * gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
|
||
5 | *
|
||
6 | * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
|
||
7 | *
|
||
8 | * This program is free software; you can redistribute it and/or
|
||
9 | * modify it under the terms of the GNU General Public License
|
||
10 | * as published by the Free Software Foundation; either version 2
|
||
11 | * of the License, or (at your option) any later version.
|
||
12 | *
|
||
13 | * This program is distributed in the hope that it will be useful,
|
||
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
16 | * GNU General Public License for more details.
|
||
17 | *
|
||
18 | * You should have received a copy of the GNU General Public License
|
||
19 | * along with this program; if not, write to the Free Software
|
||
20 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,USA.
|
||
21 | *
|
||
22 | * For more information, contact:
|
||
23 | *
|
||
24 | * Generalitat Valenciana
|
||
25 | * Conselleria d'Infraestructures i Transport
|
||
26 | * Av. Blasco Ib??ez, 50
|
||
27 | * 46010 VALENCIA
|
||
28 | * SPAIN
|
||
29 | *
|
||
30 | * +34 963862235
|
||
31 | * gvsig@gva.es
|
||
32 | * www.gvsig.gva.es
|
||
33 | *
|
||
34 | * or
|
||
35 | *
|
||
36 | * IVER T.I. S.A
|
||
37 | * Salamanca 50
|
||
38 | * 46005 Valencia
|
||
39 | * Spain
|
||
40 | *
|
||
41 | * +34 963163400
|
||
42 | * dac@iver.es
|
||
43 | */
|
||
44 | /* CVS MESSAGES:
|
||
45 | *
|
||
46 | * $Id$
|
||
47 | * $Log$
|
||
48 | 10539 | jmvivo | * Revision 1.2.2.1 2007-02-28 07:35:10 jmvivo
|
49 | * Actualizado desde el HEAD.
|
||
50 | *
|
||
51 | * Revision 1.2 2007/02/07 12:44:27 fdiaz
|
||
52 | 10174 | fdiaz | * A?adido o modificado el metodo clone para que el DwgObject se encargue de las propiedades comunes a todos los objetos.
|
53 | * A?adido el metodo fill.
|
||
54 | *
|
||
55 | * Revision 1.1 2007/02/05 07:03:22 azabala
|
||
56 | 10103 | azabala | * *** empty log message ***
|
57 | *
|
||
58 | *
|
||
59 | */
|
||
60 | package com.iver.cit.jdwglib.dwg.objects; |
||
61 | |||
62 | import com.iver.cit.jdwglib.dwg.DwgHandleReference; |
||
63 | import com.iver.cit.jdwglib.dwg.DwgObject; |
||
64 | |||
65 | public class DwgMesh extends DwgObject { |
||
66 | |||
67 | private int flags; |
||
68 | private int curveType; |
||
69 | private int mVerticies; |
||
70 | private int nVerticies; |
||
71 | private int mDensity; |
||
72 | private int nDensity; |
||
73 | private DwgHandleReference firstVertexHandle;
|
||
74 | private DwgHandleReference lastVertexHandle;
|
||
75 | private DwgHandleReference seqendHandle;
|
||
76 | |||
77 | public DwgMesh(int index) { |
||
78 | super(index);
|
||
79 | // TODO Auto-generated constructor stub
|
||
80 | } |
||
81 | |||
82 | public void setFlags(int flags) { |
||
83 | this.flags = flags;
|
||
84 | } |
||
85 | |||
86 | public void setCurveType(int curveType) { |
||
87 | this.curveType = curveType;
|
||
88 | } |
||
89 | |||
90 | public void setMVerticies(int verticies) { |
||
91 | this.mVerticies = verticies;
|
||
92 | } |
||
93 | |||
94 | public void setNVerticies(int verticies) { |
||
95 | this.nVerticies = verticies;
|
||
96 | } |
||
97 | |||
98 | public void setMDensity(int density) { |
||
99 | this.mDensity = density;
|
||
100 | } |
||
101 | |||
102 | public void setNDensity(int density) { |
||
103 | this.nDensity = density;
|
||
104 | } |
||
105 | |||
106 | public void setFirstVertexHandle(DwgHandleReference handle) { |
||
107 | this.firstVertexHandle = handle;
|
||
108 | } |
||
109 | |||
110 | public void setLastVertexHandle(DwgHandleReference handle) { |
||
111 | this.lastVertexHandle = handle;
|
||
112 | } |
||
113 | |||
114 | public void setSeqendHandle(DwgHandleReference handle) { |
||
115 | this.seqendHandle = handle;
|
||
116 | } |
||
117 | |||
118 | public int getCurveType() { |
||
119 | return curveType;
|
||
120 | } |
||
121 | |||
122 | public DwgHandleReference getFirstVertexHandle() {
|
||
123 | return firstVertexHandle;
|
||
124 | } |
||
125 | |||
126 | public int getFlags() { |
||
127 | return flags;
|
||
128 | } |
||
129 | |||
130 | public DwgHandleReference getLastVertexHandle() {
|
||
131 | return lastVertexHandle;
|
||
132 | } |
||
133 | |||
134 | public int getMDensity() { |
||
135 | return mDensity;
|
||
136 | } |
||
137 | |||
138 | public int getMVerticies() { |
||
139 | return mVerticies;
|
||
140 | } |
||
141 | |||
142 | public int getNDensity() { |
||
143 | return nDensity;
|
||
144 | } |
||
145 | |||
146 | public int getNVerticies() { |
||
147 | return nVerticies;
|
||
148 | } |
||
149 | |||
150 | public DwgHandleReference getSeqendHandle() {
|
||
151 | return seqendHandle;
|
||
152 | } |
||
153 | 10174 | fdiaz | public Object clone(){ |
154 | DwgMesh obj = new DwgMesh(index);
|
||
155 | this.fill(obj);
|
||
156 | return obj;
|
||
157 | } |
||
158 | |||
159 | protected void fill(DwgObject obj){ |
||
160 | super.fill(obj);
|
||
161 | DwgMesh myObj = (DwgMesh)obj; |
||
162 | 10103 | azabala | |
163 | 10174 | fdiaz | myObj.setCurveType(curveType); |
164 | myObj.setFirstVertexHandle(firstVertexHandle); |
||
165 | myObj.setFlags(flags); |
||
166 | myObj.setLastVertexHandle(lastVertexHandle); |
||
167 | myObj.setMDensity(mDensity); |
||
168 | myObj.setMVerticies(mVerticies); |
||
169 | myObj.setNDensity(nDensity); |
||
170 | myObj.setNVerticies(nVerticies); |
||
171 | myObj.setSeqendHandle(seqendHandle); |
||
172 | } |
||
173 | |||
174 | 10103 | azabala | } |