KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > compiere > model > X_C_PaySelectionCheck


1 /** Generated Model - DO NOT CHANGE - Copyright (C) 1999-2003 Jorg Janke **/
2 package org.compiere.model;
3 import java.util.*;
4 import java.sql.*;
5 import java.math.*;
6 import java.io.Serializable JavaDoc;
7 import org.compiere.util.*;
8 /** Generated Model for C_PaySelectionCheck
9  ** @version $Id: X_C_PaySelectionCheck.java,v 1.26 2003/10/31 05:30:52 jjanke Exp $ **/

10 public class X_C_PaySelectionCheck extends PO
11 {
12 /** Standard Constructor **/
13 public X_C_PaySelectionCheck (Properties ctx, int C_PaySelectionCheck_ID)
14 {
15 super (ctx, C_PaySelectionCheck_ID);
16 /** if (C_PaySelectionCheck_ID == 0)
17 {
18 setC_BPartner_ID (0);
19 setC_PaySelectionCheck_ID (0);
20 setC_PaySelection_ID (0);
21 setIsPrinted (false);
22 setPayAmt (Env.ZERO);
23 setPaymentRule (null);
24 setQty (0);
25 }
26  **/

27 }
28 /** Load Constructor **/
29 public X_C_PaySelectionCheck (Properties ctx, ResultSet rs)
30 {
31 super (ctx, rs);
32 }
33 /** Load Meta Data **/
34 protected POInfo initPO (Properties ctx)
35 {
36 int AD_Table_ID = 525;
37 POInfo poi = POInfo.getPOInfo (ctx, AD_Table_ID);
38 return poi;
39 }
40 public String JavaDoc toString()
41 {
42 StringBuffer JavaDoc sb = new StringBuffer JavaDoc ("X_C_PaySelectionCheck[").append(getID()).append("]");
43 return sb.toString();
44 }
45 public void setC_BPartner_ID (int C_BPartner_ID)
46 {
47 setValue ("C_BPartner_ID", new Integer JavaDoc(C_BPartner_ID));
48 }
49 public int getC_BPartner_ID()
50 {
51 Integer JavaDoc ii = (Integer JavaDoc)getValue("C_BPartner_ID");
52 if (ii == null) return 0;
53 return ii.intValue();
54 }
55 void setC_PaySelectionCheck_ID (int C_PaySelectionCheck_ID)
56 {
57 setValueNoCheck ("C_PaySelectionCheck_ID", new Integer JavaDoc(C_PaySelectionCheck_ID));
58 }
59 public int getC_PaySelectionCheck_ID()
60 {
61 Integer JavaDoc ii = (Integer JavaDoc)getValue("C_PaySelectionCheck_ID");
62 if (ii == null) return 0;
63 return ii.intValue();
64 }
65 void setC_PaySelection_ID (int C_PaySelection_ID)
66 {
67 setValueNoCheck ("C_PaySelection_ID", new Integer JavaDoc(C_PaySelection_ID));
68 }
69 public int getC_PaySelection_ID()
70 {
71 Integer JavaDoc ii = (Integer JavaDoc)getValue("C_PaySelection_ID");
72 if (ii == null) return 0;
73 return ii.intValue();
74 }
75 public void setC_Payment_ID (int C_Payment_ID)
76 {
77 if (C_Payment_ID == 0) setValue ("C_Payment_ID", null);
78  else
79 setValue ("C_Payment_ID", new Integer JavaDoc(C_Payment_ID));
80 }
81 public int getC_Payment_ID()
82 {
83 Integer JavaDoc ii = (Integer JavaDoc)getValue("C_Payment_ID");
84 if (ii == null) return 0;
85 return ii.intValue();
86 }
87 public void setDocumentNo (String JavaDoc DocumentNo)
88 {
89 setValue ("DocumentNo", DocumentNo);
90 }
91 public String JavaDoc getDocumentNo()
92 {
93 return (String JavaDoc)getValue("DocumentNo");
94 }
95 public void setIsPrinted (boolean IsPrinted)
96 {
97 setValue ("IsPrinted", new Boolean JavaDoc(IsPrinted));
98 }
99 public boolean isPrinted()
100 {
101 Boolean JavaDoc bb = (Boolean JavaDoc)getValue("IsPrinted");
102 if (bb != null) return bb.booleanValue();
103 return false;
104 }
105 public void setPayAmt (BigDecimal PayAmt)
106 {
107 if (PayAmt == null) throw new IllegalArgumentException JavaDoc ("PayAmt is mandatory");
108 setValue ("PayAmt", PayAmt);
109 }
110 public BigDecimal getPayAmt()
111 {
112 BigDecimal bd = (BigDecimal)getValue("PayAmt");
113 if (bd == null) return Env.ZERO;
114 return bd;
115 }
116 public static final String JavaDoc PAYMENTRULE_Cash = "B";
117 public static final String JavaDoc PAYMENTRULE_CreditCard = "K";
118 public static final String JavaDoc PAYMENTRULE_TransferACH = "T";
119 public static final String JavaDoc PAYMENTRULE_Check = "S";
120 public static final String JavaDoc PAYMENTRULE_OnCredit = "P";
121 public void setPaymentRule (String JavaDoc PaymentRule)
122 {
123 if (PaymentRule.equals("B") || PaymentRule.equals("K") || PaymentRule.equals("T") || PaymentRule.equals("S") || PaymentRule.equals("P"));
124  else throw new IllegalArgumentException JavaDoc ("PaymentRule Invalid value - Reference_ID=195 - B - K - T - S - P");
125 if (PaymentRule == null) throw new IllegalArgumentException JavaDoc ("PaymentRule is mandatory");
126 setValue ("PaymentRule", PaymentRule);
127 }
128 public String JavaDoc getPaymentRule()
129 {
130 return (String JavaDoc)getValue("PaymentRule");
131 }
132 public void setQty (int Qty)
133 {
134 setValue ("Qty", new Integer JavaDoc(Qty));
135 }
136 public int getQty()
137 {
138 Integer JavaDoc ii = (Integer JavaDoc)getValue("Qty");
139 if (ii == null) return 0;
140 return ii.intValue();
141 }
142 }
143
Popular Tags