01: package com.etymon.pj.object.pagemark;
02:
03: import java.io.*;
04: import java.util.*;
05: import com.etymon.pj.object.*;
06:
07: /**
08: Color operator: k.
09: @author Nassib Nassar
10: */
11: public class Xk extends PageMarkOperator {
12:
13: public Xk(PjNumber c, PjNumber m, PjNumber y, PjNumber k) {
14: _c = c;
15: _m = m;
16: _y = y;
17: _k = k;
18: }
19:
20: public PjNumber getC() {
21: return _c;
22: }
23:
24: public PjNumber getM() {
25: return _m;
26: }
27:
28: public PjNumber getY() {
29: return _y;
30: }
31:
32: public PjNumber getK() {
33: return _k;
34: }
35:
36: public long writePdf(OutputStream os) throws IOException {
37: long z = _c.writePdf(os);
38: z = z + write(os, ' ');
39: z = z + _m.writePdf(os);
40: z = z + write(os, ' ');
41: z = z + _y.writePdf(os);
42: z = z + write(os, ' ');
43: z = z + _k.writePdf(os);
44: z = z + writeln(os, " k");
45: return z;
46: }
47:
48: /**
49: Returns a deep copy of this object.
50: @return a deep copy of this object.
51: */
52: public Object clone() {
53: return this ;
54: }
55:
56: public boolean equals(Object obj) {
57: if (obj == null) {
58: return false;
59: }
60: if (obj instanceof Xk) {
61: return ((_c.equals(((Xk) obj)._c))
62: && (_m.equals(((Xk) obj)._m))
63: && (_y.equals(((Xk) obj)._y)) && (_k
64: .equals(((Xk) obj)._k)));
65: } else {
66: return false;
67: }
68: }
69:
70: private PjNumber _c;
71: private PjNumber _m;
72: private PjNumber _y;
73: private PjNumber _k;
74:
75: }
|