zsh_root
2024-01-02 7b595546af704983dbafcd0d385c8768ddacefc2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
package PbuliClass;
 
import java.awt.Color;
 
/**¶à±ßÐÎÀà*/
public class Polygon {
    String name;//¶à±ßÐεÄÃû×Ö
    int[] xs;//¶à±ßÐεÄx×ø±ê¼¯ºÏ
    int[] ys;//¶à±ßÐεÄy×ø±ê¼¯ºÏ
    String floor;//¶à±ßÐÎËùÔڵIJã
    Color color;//¶à±ßÐεÄÑÕÉ«
    Color colos = null;
    int polygon_bian;//¶à±ßÐεıßÊý
    int x0;//¶à±ßÐεĵÚÒ»¸öµãx×ø±ê
    int y0;//¶à±ßÐεĵÚÒ»¸öµãy×ø±ê
    
    public Polygon() {
        
    }
    
    public Polygon(String name,String floor,int polygon_bian,int[] xs,int[] ys,int x0,int y0) {
        this.name=name;
        this.floor=floor;
        this.polygon_bian=polygon_bian;
        this.xs=xs;
        this.ys=ys;
        this.x0=x0;
        this.y0=y0;
    }
    
    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }
    public int[] getXs() {
        return xs;
    }
    public void setXs(int[] xs) {
        this.xs = xs;
    }
    public int[] getYs() {
        return ys;
    }
    public void setYs(int[] ys) {
        this.ys = ys;
    }
    public String getFloor() {
        return floor;
    }
    public void setFloor(String floor) {
        this.floor = floor;
    }
    public Color getColor() {
        return color;
    }
    public void setColor(String xuanze) {        
        switch (xuanze) {
        case "ºìÉ«":
            colos=Color.red ;                        
            break;
        case "À¶É«":
            colos=Color.blue ;                        
            break;
        case "ÂÌÉ«":
            colos=Color.green ;                        
            break;
        case "ºÚÉ«":
            colos=Color.black ;                        
            break;
        case "°×É«":
            colos=Color.white ;                        
            break;
        case "Æ·ºì":
            colos=Color.pink ;                        
            break;                                
        }
        this.color = colos;
    }
 
    public int getPlygon_bian() {
        return polygon_bian;
    }
    public void setPolygon_bian(int polygon_bian) {
        this.polygon_bian = polygon_bian;
    }
    public int getX0() {
        return x0;
    }
 
    public void setX0(int x0) {
        this.x0 = x0;
    }
 
    public int getY0() {
        return y0;
    }
 
    public void setY0(int y0) {
        this.y0 = y0;
    }
 
}