Statistics
| Revision:

svn-gvsig-desktop / branches / v10 / libraries / libDwg / src / com / iver / cit / jdwglib / dwg / objects / DwgBlockControl.java @ 10539

History | View | Annotate | Download (2.74 KB)

1
/* jdwglib. Java Library for reading Dwg files.
2
 * 
3
 * Author: Jose Morell Rama (jose.morell@gmail.com).
4
 * Port from the Pythoncad Dwg library by Art Haas.
5
 *
6
 * Copyright (C) 2005 Jose Morell, IVER TI S.A. 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
 * Jose Morell (jose.morell@gmail.com)
25
 * 
26
 * or
27
 *
28
 * IVER TI S.A.
29
 *  C/Salamanca, 50
30
 *  46005 Valencia
31
 *  Spain
32
 *  +34 963163400
33
 *  dac@iver.es
34
 */
35
package com.iver.cit.jdwglib.dwg.objects;
36

    
37
import java.util.Vector;
38

    
39
import com.iver.cit.jdwglib.dwg.DwgHandleReference;
40
import com.iver.cit.jdwglib.dwg.DwgObject;
41

    
42
/**
43
 * The DwgBlockControl class represents a DWG Block control
44
 * 
45
 * @author jmorell
46
 */
47
public class DwgBlockControl extends DwgObject {
48

    
49
        private DwgHandleReference nullHandle = null;
50
        private Vector code2Handles;
51
        private DwgHandleReference modelSpaceHandle = null;
52
        private DwgHandleReference paperSpaceHandle = null;
53
        
54
        public DwgBlockControl(int index) {
55
                super(index);
56
        }
57
        
58
        public Vector getCode2Handles() {
59
                return code2Handles;
60
        }
61
        public void setCode2Handles(Vector code2Handles) {
62
                this.code2Handles = code2Handles;
63
        }
64
        public DwgHandleReference getModelSpaceHandle() {
65
                return modelSpaceHandle;
66
        }
67
        public void setModelSpaceHandle(DwgHandleReference modelSpaceHandle) {
68
                this.modelSpaceHandle = modelSpaceHandle;
69
        }
70
        public DwgHandleReference getNullHandle() {
71
                return nullHandle;
72
        }
73
        public void setNullHandle(DwgHandleReference nullHandle) {
74
                this.nullHandle = nullHandle;
75
        }
76
        public DwgHandleReference getPaperSpaceHandle() {
77
                return paperSpaceHandle;
78
        }
79
        public void setPaperSpaceHandle(DwgHandleReference paperSpaceHandle) {
80
                this.paperSpaceHandle = paperSpaceHandle;
81
        }
82
        public Object clone(){
83
                DwgBlockControl obj = new DwgBlockControl(index);
84
                this.fill(obj);
85
                return obj;
86
        }
87
        
88
        protected void fill(DwgObject obj){
89
                super.fill(obj);
90
                DwgBlockControl myObj = (DwgBlockControl)obj;
91

    
92
                myObj.setCode2Handles(code2Handles);
93
                myObj.setModelSpaceHandle(modelSpaceHandle);
94
                myObj.setNullHandle(nullHandle);
95
                myObj.setPaperSpaceHandle(paperSpaceHandle);
96
        }
97

    
98
}