001: package demo.notification.whiteboard;
002:
003: /**
004:
005: * UpdateLine.java
006:
007: *
008:
009: *
010:
011: * Created: Sun Feb 6 19:05:46 2000
012:
013: *
014:
015: * @author Alphonse Bendt
016:
017: * @version
018:
019: */
020:
021: // klasse kapselt alle A"nderungen in einem PixelImage
022: public class UpdateLine implements java.io.Serializable {
023:
024: int x0, x1, y1, y0, red, green, blue, brushSize;
025:
026: boolean clear = false;
027:
028: public UpdateLine(boolean clear) {
029:
030: this .clear = true;
031:
032: }
033:
034: public UpdateLine(int x0, int y0,
035:
036: int x1, int y1,
037:
038: int red, int green, int blue, int brushSize) {
039:
040: this .x0 = x0;
041:
042: this .y0 = y0;
043:
044: this .x1 = x1;
045:
046: this .y1 = y1;
047:
048: this .red = red;
049:
050: this .green = green;
051:
052: this .blue = blue;
053:
054: this .brushSize = brushSize;
055:
056: }
057:
058: public boolean clearScreen() {
059:
060: return clear;
061:
062: }
063:
064: public int getX0() {
065:
066: return x0;
067:
068: }
069:
070: public int getY0() {
071:
072: return y0;
073:
074: }
075:
076: public int getX1() {
077:
078: return x1;
079:
080: }
081:
082: public int getY1() {
083:
084: return y1;
085:
086: }
087:
088: public int getRed() {
089:
090: return red;
091:
092: }
093:
094: public int getGreen() {
095:
096: return green;
097:
098: }
099:
100: public int getBlue() {
101:
102: return blue;
103:
104: }
105:
106: public int getBrushSize() {
107:
108: return brushSize;
109:
110: }
111:
112: public String toString() {
113:
114: String s = new String();
115:
116: s += "x0:" + x0;
117:
118: s += " y0:" + y0;
119:
120: s += " x1:" + x1;
121:
122: s += " y1:" + y1;
123:
124: s += " red:" + red;
125:
126: s += " green:" + green;
127:
128: s += " blue:" + blue;
129:
130: s += " brushSize:" + brushSize + "\n";
131:
132: return s;
133:
134: }
135:
136: } // UpdateLine
|