Revision 10820 trunk/libraries/libDwg/src/com/iver/cit/jdwglib/dwg/DwgObjectFactory.java
DwgObjectFactory.java | ||
---|---|---|
45 | 45 |
* |
46 | 46 |
* $Id$ |
47 | 47 |
* $Log$ |
48 |
* Revision 1.17 2007-03-06 19:39:38 azabala |
|
48 |
* Revision 1.18 2007-03-20 19:55:27 azabala |
|
49 |
* source code cleaning |
|
50 |
* |
|
51 |
* Revision 1.17 2007/03/06 19:39:38 azabala |
|
49 | 52 |
* Changes to adapt dwg 12 to general architecture |
50 | 53 |
* |
51 | 54 |
* Revision 1.16 2007/03/02 20:31:22 azabala |
... | ... | |
123 | 126 |
import com.iver.cit.jdwglib.dwg.objects.DwgLayerControl; |
124 | 127 |
import com.iver.cit.jdwglib.dwg.objects.DwgLayerIndex; |
125 | 128 |
import com.iver.cit.jdwglib.dwg.objects.DwgLine; |
126 |
import com.iver.cit.jdwglib.dwg.objects.DwgLinearDimension; |
|
127 | 129 |
import com.iver.cit.jdwglib.dwg.objects.DwgLwPolyline; |
128 | 130 |
import com.iver.cit.jdwglib.dwg.objects.DwgMText; |
131 |
import com.iver.cit.jdwglib.dwg.objects.DwgMeshPolyline; |
|
129 | 132 |
import com.iver.cit.jdwglib.dwg.objects.DwgOle2Frame; |
133 |
import com.iver.cit.jdwglib.dwg.objects.DwgPFacePolyline; |
|
130 | 134 |
import com.iver.cit.jdwglib.dwg.objects.DwgPoint; |
131 | 135 |
import com.iver.cit.jdwglib.dwg.objects.DwgPolyline2D; |
132 | 136 |
import com.iver.cit.jdwglib.dwg.objects.DwgPolyline3D; |
... | ... | |
140 | 144 |
import com.iver.cit.jdwglib.dwg.objects.DwgText; |
141 | 145 |
import com.iver.cit.jdwglib.dwg.objects.DwgVertex2D; |
142 | 146 |
import com.iver.cit.jdwglib.dwg.objects.DwgVertex3D; |
147 |
import com.iver.cit.jdwglib.dwg.objects.DwgVertexMesh; |
|
148 |
import com.iver.cit.jdwglib.dwg.objects.DwgVertexPFace; |
|
149 |
import com.iver.cit.jdwglib.dwg.objects.DwgVertexPFaceFace; |
|
143 | 150 |
import com.iver.cit.jdwglib.dwg.objects.DwgXRecord; |
144 | 151 |
|
145 | 152 |
|
... | ... | |
187 | 194 |
if (type == 0x11) { |
188 | 195 |
obj = new DwgArc(index); |
189 | 196 |
obj.setGraphicsFlag(true); |
190 |
} else if (type == 0x12) { |
|
197 |
} else if (type == 0x1D) { |
|
198 |
obj = new DwgPFacePolyline(index); |
|
199 |
obj.setGraphicsFlag(true); |
|
200 |
} else if (type == 0x1E) { |
|
201 |
obj = new DwgMeshPolyline(index); |
|
202 |
obj.setGraphicsFlag(true); |
|
203 |
} |
|
204 |
else if (type == 0x12) { |
|
191 | 205 |
obj = new DwgCircle(index); |
192 | 206 |
obj.setGraphicsFlag(true); |
193 | 207 |
} else if (type == 0x13) { |
... | ... | |
208 | 222 |
} else if (type == 0x0B) { |
209 | 223 |
obj = new DwgVertex3D(index); |
210 | 224 |
obj.setGraphicsFlag(true); |
211 |
} else if (type == 0x6) { |
|
225 |
} else if (type == 0x0C) { |
|
226 |
obj = new DwgVertexMesh(index); |
|
227 |
obj.setGraphicsFlag(true); |
|
228 |
}else if (type == 0x0D) { |
|
229 |
obj = new DwgVertexPFace(index); |
|
230 |
obj.setGraphicsFlag(true); |
|
231 |
}else if (type == 0x0E) { |
|
232 |
obj = new DwgVertexPFaceFace(index); |
|
233 |
obj.setGraphicsFlag(true); |
|
234 |
} |
|
235 |
else if (type == 0x6) { |
|
212 | 236 |
obj = new DwgSeqend(index); |
213 | 237 |
obj.setGraphicsFlag(true); |
214 | 238 |
} else if (type == 0x1) { |
... | ... | |
247 | 271 |
} else if (type == 0x2C) { |
248 | 272 |
obj = new DwgMText(index); |
249 | 273 |
obj.setGraphicsFlag(true); |
250 |
} else if (type == 0x1F) { |
|
251 |
obj = new DwgSolid(index); |
|
252 |
obj.setGraphicsFlag(true); |
|
253 |
} else if (type == 0x23) { |
|
274 |
} |
|
275 |
// else if (type == 0x1F) { |
|
276 |
// obj = new DwgSolid(index); |
|
277 |
// obj.setGraphicsFlag(true); |
|
278 |
// } |
|
279 |
else if (type == 0x23) { |
|
254 | 280 |
obj = new DwgEllipse(index); |
255 | 281 |
obj.setGraphicsFlag(true); |
256 | 282 |
} else if (type == 0x24) { |
257 | 283 |
obj = new DwgSpline(index); |
258 | 284 |
obj.setGraphicsFlag(true); |
259 |
} else if (type == 0x15) { |
|
260 |
obj = new DwgLinearDimension(index); |
|
261 |
obj.setGraphicsFlag(true); |
|
262 | 285 |
} |
286 |
// else if (type == 0x15) { |
|
287 |
// obj = new DwgLinearDimension(index); |
|
288 |
// obj.setGraphicsFlag(true); |
|
289 |
// } |
|
263 | 290 |
/* |
264 | 291 |
* Segun los foros de OpenDWG: |
265 | 292 |
* OLE2FRAME - 74 -> 0X4A |
... | ... | |
272 | 299 |
else if (type == 0x4D) { |
273 | 300 |
obj = new DwgLwPolyline(index); |
274 | 301 |
obj.setGraphicsFlag(true); |
275 |
} else if (type == 0x4A){ |
|
302 |
} |
|
303 |
/* |
|
304 |
else if (type == 0x4A){ |
|
276 | 305 |
obj = new DwgOle2Frame(index); |
277 | 306 |
obj.setGraphicsFlag(false); |
278 |
}else if (type == 0x4E){ |
|
307 |
} |
|
308 |
|
|
309 |
|
|
310 |
else if (type == 0x4E){ |
|
279 | 311 |
obj = new DwgHatch(index); |
280 | 312 |
obj.setGraphicsFlag(true); |
281 | 313 |
} |
282 |
/* |
|
314 |
|
|
283 | 315 |
else if (type == 0x4E) { |
284 | 316 |
obj = new DwgLwPolyline(index); |
285 | 317 |
obj.setGraphicsFlag(true); |
... | ... | |
361 | 393 |
* Creates a DWG object for DWG 12 files. |
362 | 394 |
* |
363 | 395 |
* */ |
364 |
//TODO REVISAR POLYLINE Y VERTEX |
|
365 | 396 |
public DwgObject create(byte kind, int index){ |
366 | 397 |
switch(kind){ |
367 | 398 |
case 1: |
Also available in: Unified diff